Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to parse input with a square bracket #389

Closed
ArsalanKhairani opened this issue Apr 26, 2018 · 3 comments
Closed

Unable to parse input with a square bracket #389

ArsalanKhairani opened this issue Apr 26, 2018 · 3 comments

Comments

@ArsalanKhairani
Copy link

ArsalanKhairani commented Apr 26, 2018

Expected behavior

Input should parse successfully.

Actual behavior

[USER]: Unexpected token d in JSON at position 3
SyntaxError: Unexpected token d in JSON at position 3
    at JSON.parse (<anonymous>)
    at parse_string (https://rawgit.com/jcubic/jquery.terminal/master/js/jquery.terminal.js:3508:29)
    at Object.parse_argument (https://rawgit.com/jcubic/jquery.terminal/master/js/jquery.terminal.js:3519:28)
    at https://rawgit.com/jcubic/jquery.terminal/master/js/jquery.terminal.js:3564:35
    at https://rawgit.com/jcubic/jquery.terminal/master/js/jquery.terminal.js:2810:24
    at Function.map (https://code.jquery.com/jquery-3.1.1.min.js:2:3409)
    at process_command (https://rawgit.com/jcubic/jquery.terminal/master/js/jquery.terminal.js:2804:26)
    at Object.split_command (https://rawgit.com/jcubic/jquery.terminal/master/js/jquery.terminal.js:3563:20)
    at Object.commands (https://rawgit.com/jcubic/jquery.terminal/master/js/jquery.terminal.js:4907:47)
    at Object.ENTER (https://rawgit.com/jcubic/jquery.terminal/master/js/jquery.terminal.js:1214:29)

Steps to reproduce

> {"demo": ["error"]}

Works okay if you remove the space before [.

> {"demo":["error"]}

Browser and OS

Google Chrome Version 65.0.3325.181 (Official Build) (64-bit) | Linux.
Tried on codepen and it's reproducible there as well.

jcubic added a commit that referenced this issue Apr 26, 2018
@jcubic
Copy link
Owner

jcubic commented Apr 26, 2018

Fixed in devel branch

@ArsalanKhairani
Copy link
Author

@jcubic: Appreciate the quick response 👍

@jcubic
Copy link
Owner

jcubic commented May 13, 2018

released in version 1.15.0

@jcubic jcubic closed this as completed May 13, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants