Skip to content

Commit 7f79849

Browse files
authored
Merge pull request #160 from csgofloat/fix/inventory-fallback-status
Enables Inventory Fallback for 400/500 HTTP Errors
2 parents e592a48 + c960bcf commit 7f79849

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib/page_scripts/trade_offer.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ function injectInventoryFallback() {
9595
fOnFailure: () => any,
9696
fOnComplete: () => any
9797
) {
98-
if (strUrl.startsWith(g_strInventoryLoadURL!) && transport.status === 429) {
98+
if (strUrl.startsWith(g_strInventoryLoadURL!) && transport.status >= 400) {
9999
// User was rate limited... try the fallback.
100100
try {
101101
const newInventory = await fetchInventoryWithAPIKey();

0 commit comments

Comments
 (0)