web: Switch from JSON.parse(xhr.responseText) to xhr.responseJSON.

This commit is contained in:
Alex Vandiver
2023-07-18 18:14:56 +00:00
committed by Tim Abbott
parent d05a1e9efa
commit 7efe989a72
17 changed files with 34 additions and 36 deletions

View File

@@ -280,7 +280,7 @@ function create_stream() {
// The rest of the work is done via the subscribe event we will get
},
error(xhr) {
const msg = JSON.parse(xhr.responseText).msg;
const msg = xhr.responseJSON.msg;
if (msg.includes("access")) {
// If we can't access the stream, we can safely
// assume it's a duplicate stream that we are not invited to.