fix bug of quiting for currently working faction

This commit is contained in:
Olivier Gagnon
2022-01-11 12:21:03 -05:00
parent fa0f5cb451
commit ea2f53e3b4
5 changed files with 27 additions and 22 deletions

View File

@@ -1821,7 +1821,7 @@ export function getNextCompanyPosition(
}
export function quitJob(this: IPlayer, company: string): void {
if (this.isWorking == true && this.workType == "Working for Company" && this.companyName == company) {
if (this.isWorking == true && this.workType.includes("Working for Company") && this.companyName == company) {
this.isWorking = false;
this.companyName = "";
}