martin-g commented on a change in pull request #384: WICKET-6703 replace eval
with jQuery.globalEval; add suspend/notify
URL: https://github.com/apache/wicket/pull/384#discussion_r331761639
##########
File path:
wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
##########
@@ -350,6 +350,44 @@
*/
Wicket.Ajax.Call = Wicket.Class.create();
+ Wicket.Ajax.Call._suspended = 0;
+
+ Wicket.Ajax.Call.currentNotify = undefined;
+
+ Wicket.Ajax.Call.suspend = function () {
+ if (typeof (Wicket.Ajax.Call.currentNotify) != "function") {
+ Wicket.Log.error("Can't suspend: no evaluation in
process");
+ return;
Review comment:
IMO this should either log error and return a no-op function or throw an
exception instead of just logging.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services