You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2014/02/12 12:20:19 UTC

[jira] [Commented] (WICKET-4592) WicketAjaxDebug.logError used in Wicket.Head.addJavascript - JS error when wicket-ajax-debug.js not loaded

    [ https://issues.apache.org/jira/browse/WICKET-4592?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13899014#comment-13899014 ] 

ASF GitHub Bot commented on WICKET-4592:
----------------------------------------

Github user tgoetz closed the pull request at:

    https://github.com/apache/wicket/pull/15


> WicketAjaxDebug.logError used in Wicket.Head.addJavascript - JS error when wicket-ajax-debug.js not loaded
> ----------------------------------------------------------------------------------------------------------
>
>                 Key: WICKET-4592
>                 URL: https://issues.apache.org/jira/browse/WICKET-4592
>             Project: Wicket
>          Issue Type: Bug
>    Affects Versions: 1.5.7
>            Reporter: Tom Kmec
>            Assignee: Martin Grigorov
>             Fix For: 1.5.8, 6.0.0-beta3
>
>
> Wicket.Head.addJavascript (defined in wicket-ajax.js) encapsulates javascript in this code:
> content = 'try{'+content+'}catch(e){WicketAjaxDebug.logError(e);}'; 
> However, WicketAjaxDebug can be undefined as it's declared in wicket-ajax-debug.js which might not be included. As a consequence, catch block will fail and obfuscate any error catched.
> I believe this catch block should call Wicket.Log.error(e) instead.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)