API: Fixed ns.singularity.donateToFaction being able to donate to SoA (#1595)

Fixed ns.singularity.donateToFaction bug
Fixed a bug within singularity.donateToFaction where you could use it to donate to Shadows Of Anarchy
Also updated the Node version in package-lock.json to 18
This commit is contained in:
Fireball5939
2024-08-17 16:10:01 -05:00
committed by GitHub
parent cacecda72f
commit 701c5d8e64
2 changed files with 6 additions and 2 deletions
+5 -1
View File
@@ -968,7 +968,11 @@ export function NetscriptSingularity(): InternalAPI<ISingularity> {
helpers.log(ctx, () => `You can't donate to '${facName}' because you are managing a gang for it`);
return false;
}
if (faction.name === FactionName.ChurchOfTheMachineGod || faction.name === FactionName.Bladeburners) {
if (
faction.name === FactionName.ChurchOfTheMachineGod ||
faction.name === FactionName.Bladeburners ||
faction.name === FactionName.ShadowsOfAnarchy
) {
helpers.log(ctx, () => `You can't donate to '${facName}' because they do not accept donations`);
return false;
}