fix: selling items in old builds #3023

Merged
Sainan merged 4 commits from VoltPrime/SpaceNinjaServer:sell-fix into main 2025-11-14 01:50:03 -08:00
Showing only changes of commit 9c70e90db6 - Show all commits

View File

@@ -28,13 +28,14 @@ export const sellController: RequestHandler = async (req, res) => {
let sellCurrency = "SC_RegularCredits";
if (payload.SellCurrency) {
sellCurrency = payload.SellCurrency;
}
if (payload.SellForFusionPoints || payload.SellForPrimeBucks) {
if (payload.SellForFusionPoints) {
sellCurrency = "SC_FusionPoints";
}
if (payload.SellForPrimeBucks) {
sellCurrency = "SC_PrimeBucks";
} else {
if (payload.SellForFusionPoints || payload.SellForPrimeBucks) {
if (payload.SellForFusionPoints) {
sellCurrency = "SC_FusionPoints";
}
if (payload.SellForPrimeBucks) {
sellCurrency = "SC_PrimeBucks";
}
}
}
if (sellCurrency == "SC_RegularCredits") {
@@ -358,7 +359,7 @@ interface ISellRequest {
WeaponSkins?: ISellItem[]; // SNS specific field
};
SellPrice: number;
SellCurrency:
SellCurrency?:
| "SC_RegularCredits"
| "SC_PrimeBucks"
| "SC_FusionPoints"