fix: display bug when activating riven via mods console
All checks were successful
Build / build (22) (push) Successful in 37s
Build / build (18) (push) Successful in 51s
Build / build (20) (push) Successful in 1m4s
Build / build (18) (pull_request) Successful in 40s
Build / build (20) (pull_request) Successful in 49s
Build / build (22) (pull_request) Successful in 52s
All checks were successful
Build / build (22) (push) Successful in 37s
Build / build (18) (push) Successful in 51s
Build / build (20) (push) Successful in 1m4s
Build / build (18) (pull_request) Successful in 40s
Build / build (20) (pull_request) Successful in 49s
Build / build (22) (pull_request) Successful in 52s
This commit is contained in:
parent
e2ee1172ed
commit
bf00f61e24
@ -1,3 +1,4 @@
|
|||||||
|
import { toOid } from "@/src/helpers/inventoryHelpers";
|
||||||
import { getJSONfromString } from "@/src/helpers/stringHelpers";
|
import { getJSONfromString } from "@/src/helpers/stringHelpers";
|
||||||
import { addMods, getInventory } from "@/src/services/inventoryService";
|
import { addMods, getInventory } from "@/src/services/inventoryService";
|
||||||
import { getAccountIdForRequest } from "@/src/services/loginService";
|
import { getAccountIdForRequest } from "@/src/services/loginService";
|
||||||
@ -47,8 +48,13 @@ export const activateRandomModController: RequestHandler = async (req, res) => {
|
|||||||
UpgradeFingerprint: JSON.stringify({ challenge: fingerprintChallenge })
|
UpgradeFingerprint: JSON.stringify({ challenge: fingerprintChallenge })
|
||||||
}) - 1;
|
}) - 1;
|
||||||
await inventory.save();
|
await inventory.save();
|
||||||
|
// For some reason, in this response, the UpgradeFingerprint is simply a nested object and not a string
|
||||||
res.json({
|
res.json({
|
||||||
NewMod: inventory.Upgrades[upgradeIndex].toJSON()
|
NewMod: {
|
||||||
|
UpgradeFingerprint: { challenge: fingerprintChallenge },
|
||||||
|
ItemType: inventory.Upgrades[upgradeIndex].ItemType,
|
||||||
|
ItemId: toOid(inventory.Upgrades[upgradeIndex]._id)
|
||||||
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user