[X2Go-Commits] [x2gohtmlclient] 02/02: Improve JSON parsing.
git-admin at x2go.org
git-admin at x2go.org
Tue Jun 22 01:22:31 CEST 2021
This is an automated email from the git hooks/post-receive script.
x2go pushed a commit to branch master
in repository x2gohtmlclient.
commit 366228198f991bd273d92f8590b1766d36d7b66d
Author: Oleksandr Shneyder <o.shneyder at phoca-gmbh.de>
Date: Mon Jun 21 18:22:20 2021 -0500
Improve JSON parsing.
---
src/x2gohtmlclient.js | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/x2gohtmlclient.js b/src/x2gohtmlclient.js
index cad9dec..6764dad 100644
--- a/src/x2gohtmlclient.js
+++ b/src/x2gohtmlclient.js
@@ -57,7 +57,8 @@ X2GoHTMLClient
console.log(this);
console.log(this.response);
- let resp = JSON.parse(this.response.substr(this.response.indexOf('{')));
+ let jsonSep='__STARTJSON__{';
+ let resp = JSON.parse(this.response.substr(this.response.indexOf(jsonSep)+jsonSep.length-1));
console.log(resp);
if (resp.status != 0)
{
--
Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2gohtmlclient.git
More information about the x2go-commits
mailing list