Skip to content

Commit

Permalink
throw the original underlining error instead of 'offline'
Browse files Browse the repository at this point in the history
  • Loading branch information
endel committed Jun 3, 2024
1 parent b0fa397 commit fd467fb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "colyseus.js",
"version": "0.15.21",
"version": "0.15.22",
"description": "Colyseus Multiplayer SDK for JavaScript/TypeScript",
"author": "Endel Dreyer",
"license": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion src/HTTP.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export class HTTP {
const status = e.statusCode; // || -1
const message = e.data?.error || e.statusMessage || e.message; // || "offline"

if (status === undefined && message === undefined) {
if (!status && !message) {
throw e;
}

Expand Down

0 comments on commit fd467fb

Please sign in to comment.