Merge pull request #4229 from tgxworld/uncaught_error_warning

FIX: Don't throw uncaught error warning when in readonly mode.
This commit is contained in:
Guo Xiang Tan 2016-05-25 23:09:51 +08:00
commit 2dcabd4762

View file

@ -124,6 +124,9 @@ export default class {
const postNumbers = Object.keys(newTimings).map(v => parseInt(v, 10));
controller.readPosts(topicId, postNumbers);
}
}).catch(e => {
const error = e.jqXHR;
if (error.status === 405 && error.responseJSON.error_type === "read_only") return;
});
} else if (this._anonCallback) {
// Anonymous viewer - save to localStorage