Merge pull request #2507 from MartinFournier/fix/quit-job-error

Fix crash when quitting job
This commit is contained in:
hydroflame 2022-01-09 12:58:03 -05:00 committed by GitHub
commit 46a8de4924
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1769,6 +1769,7 @@ export function getNextCompanyPosition(
//return the player's "nextCompanyPosition". Otherwise return the entryposType
//Employed at this company, so just return the next position if it exists.
const currentPositionName = this.jobs[this.companyName];
if (!currentPositionName) return entryPosType;
const currentPosition = CompanyPositions[currentPositionName];
if (
(currentPosition.isSoftwareJob() && entryPosType.isSoftwareJob()) ||