You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I configure jquery-textcomplete with a completion strategy based on @, and type @xyz and backspace over it a few times (and keep pressing backspace after I've erased all input), sometimes I get it to throw this exception:
Uncaught client exception: TypeError: Cannot call method 'replace' of undefined
at Function.jQuery.extend.camelCase (http://test:1080/static/lib/jquery/jquery.js:620:17)
at Function.jQuery.extend.css (http://test:1080/static/lib/jquery/jquery.js:7048:22)
at null.<anonymous> (http://test:1080/static/lib/jquery/jquery.js:6920:12)
at Function.jQuery.extend.access (http://test:1080/static/lib/jquery/jquery.js:885:8)
at jQuery.fn.extend.css (http://test:1080/static/lib/jquery/jquery.js:6902:17)
at ListView.$.extend.setPosition (http://test:1080/static/lib/jquery-textcomplete/jquery.textcomplete.js:462:18)
at Completer.$.extend.renderList (http://test:1080/static/lib/jquery-textcomplete/jquery.textcomplete.js:179:18)
at http://test:1080/static/lib/jquery-textcomplete/jquery.textcomplete.js:196:16
at http://test:1080/static/lib/jquery-textcomplete/jquery.textcomplete.js:76:20
I think this happens when the server is slow to respond (I was introducing intentional delays to reproduce another bug) and the callback arrives late.
This is easy to fix (don't call $el.css(null)); would you like a PR?
The text was updated successfully, but these errors were encountered:
Hi @metamatt
Thank you for reporting the issue! This is a bug 👾
setPosition is called with the result of getCaretPosition (here) and getCaretPosition returns undefined when a caret is located at the head of textarea (here).
Don't call $el.css(null) is 🆗 , but I think removing this line is better :)
If I configure jquery-textcomplete with a completion strategy based on
@
, and type@xyz
and backspace over it a few times (and keep pressing backspace after I've erased all input), sometimes I get it to throw this exception:I think this happens when the server is slow to respond (I was introducing intentional delays to reproduce another bug) and the callback arrives late.
This is easy to fix (don't call
$el.css(null)
); would you like a PR?The text was updated successfully, but these errors were encountered: