mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-23 06:32:26 +01:00
Merge pull request #3068 from phyzical/hotfix/2902
Fix for work in progress modal when augmenting
This commit is contained in:
commit
459296c160
@ -933,6 +933,8 @@ export function startFactionSecurityWork(this: IPlayer, faction: Faction): void
|
|||||||
export function workForFaction(this: IPlayer, numCycles: number): boolean {
|
export function workForFaction(this: IPlayer, numCycles: number): boolean {
|
||||||
const faction = Factions[this.currentWorkFactionName];
|
const faction = Factions[this.currentWorkFactionName];
|
||||||
|
|
||||||
|
if (!faction) { return false; }
|
||||||
|
|
||||||
//Constantly update the rep gain rate
|
//Constantly update the rep gain rate
|
||||||
switch (this.factionWorkType) {
|
switch (this.factionWorkType) {
|
||||||
case CONSTANTS.FactionWorkHacking:
|
case CONSTANTS.FactionWorkHacking:
|
||||||
|
@ -36,6 +36,18 @@ export function WorkInProgressRoot(): React.ReactElement {
|
|||||||
const router = use.Router();
|
const router = use.Router();
|
||||||
|
|
||||||
const faction = Factions[player.currentWorkFactionName];
|
const faction = Factions[player.currentWorkFactionName];
|
||||||
|
if (!faction) {
|
||||||
|
return (
|
||||||
|
<Grid container direction="column" justifyContent="center" alignItems="center" style={{ minHeight: "100vh" }}>
|
||||||
|
<Grid item>
|
||||||
|
<Typography>
|
||||||
|
Something has gone wrong, you cannot work for {player.currentWorkFactionName || "(Faction not found)"} at this time.
|
||||||
|
</Typography>
|
||||||
|
</Grid>
|
||||||
|
</Grid>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
if (player.workType == CONSTANTS.WorkTypeFaction) {
|
if (player.workType == CONSTANTS.WorkTypeFaction) {
|
||||||
if (!faction) {
|
if (!faction) {
|
||||||
return <>
|
return <>
|
||||||
|
Loading…
Reference in New Issue
Block a user