Skip to content

Commit 76c7639

Browse files
committed
If a file load 404s then handle this case, as it'll return the 404 page as the response type which will then try to be parsed.
1 parent f3d9f14 commit 76c7639

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

src/loader/File.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,14 @@ var File = new Class({
8686
{
8787
this.resetXHR();
8888

89-
this.callback(this, true);
89+
if (event.target && event.target.status !== 200)
90+
{
91+
this.callback(this, false);
92+
}
93+
else
94+
{
95+
this.callback(this, true);
96+
}
9097
},
9198

9299
onError: function (event)

0 commit comments

Comments
 (0)