Condensed if-else pair to else if statement

This commit is contained in:
frutescens 2024-11-09 19:52:54 -08:00
parent 1f72a802ec
commit bae61cf6dd

View File

@ -179,12 +179,10 @@ export class GameOverPhase extends BattlePhase {
if (!Utils.isLocal || Utils.isLocalServerConnected) { if (!Utils.isLocal || Utils.isLocalServerConnected) {
pokerogueApi.savedata.session.newclear({ slot: this.scene.sessionSlotId, isVictory: this.isVictory, clientSessionId: clientSessionId }) pokerogueApi.savedata.session.newclear({ slot: this.scene.sessionSlotId, isVictory: this.isVictory, clientSessionId: clientSessionId })
.then((success) => doGameOver(!!success)); .then((success) => doGameOver(!!success));
} else { } else if (this.isVictory) {
if (this.isVictory) { this.scene.gameData.offlineNewClear(this.scene).then(result => {
this.scene.gameData.offlineNewClear(this.scene).then(result => { doGameOver(result);
doGameOver(result); });
});
}
} }
} }