fix: replace the wrong param name willExist (#2389)

This commit is contained in:
wxy
2023-10-10 21:47:38 +08:00
committed by GitHub
parent 9aec69ef47
commit 684cbdb951
20 changed files with 41 additions and 41 deletions

View File

@ -173,7 +173,7 @@ class TokenEditPage extends React.Component {
);
}
submitTokenEdit(willExist) {
submitTokenEdit(exitAfterSave) {
const token = Setting.deepCopy(this.state.token);
TokenBackend.updateToken(this.state.token.owner, this.state.tokenName, token)
.then((res) => {
@ -183,7 +183,7 @@ class TokenEditPage extends React.Component {
tokenName: this.state.token.name,
});
if (willExist) {
if (exitAfterSave) {
this.props.history.push("/tokens");
} else {
this.props.history.push(`/tokens/${this.state.token.name}`);