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

Tokenizer crashes if the input terminates with a dot character. #1658

Closed
asteinha opened this issue Apr 10, 2019 · 0 comments
Closed

Tokenizer crashes if the input terminates with a dot character. #1658

asteinha opened this issue Apr 10, 2019 · 0 comments

Comments

@asteinha
Copy link
Contributor

Tokenizer crashes at:
https://github.com/beautify-web/js-beautify/blob/25f56a2a4b031e1eb323424ece104427fa29af96/python/jsbeautifier/javascript/tokenizer.py#L220
With:
elif c == '.' and bool(dot_pattern.match(self._input.peek(1))):
TypeError: expected string or buffer
If the input string terminates with a dot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants