This is an automated email from the ASF dual-hosted git repository.

svenmeier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/wicket.git


View the commit online:
https://github.com/apache/wicket/commit/766294a3660c5aa74f4b6dc4ae968717ac27c2e7

The following commit(s) were added to refs/heads/master by this push:
     new 766294a  WICKET-6703 fixed lint
766294a is described below

commit 766294a3660c5aa74f4b6dc4ae968717ac27c2e7
Author: Sven Meier <svenme...@apache.org>
AuthorDate: Wed Nov 20 21:36:31 2019 +0100

    WICKET-6703 fixed lint
---
 .../apache/wicket/ajax/res/js/wicket-ajax-jquery.js   | 19 ++++++++++---------
 wicket-core/src/test/js/head.js                       |  2 +-
 2 files changed, 11 insertions(+), 10 deletions(-)

diff --git 
a/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js 
b/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
index 302489c..2191fb9 100644
--- 
a/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
+++ 
b/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
@@ -373,7 +373,7 @@
                                suspension.release();
                                suspension = null;
                        }
-               }
+               };
        };
 
        Wicket.Ajax.Call.prototype = {
@@ -1910,26 +1910,27 @@
                                                                                
                                                                release: 
function() {
                                                                        
suspension.suspended--;
-                                                                       if 
(suspension.suspended == 0) {
+                                                                       if 
(suspension.suspended === 0) {
                                                                                
notify();
                                                                        }
                                                                }
                                                        };
 
+                                                       // serialize the 
element content to string
+                                                       var text = 
Wicket.DOM.serializeNodeChildren(node);
+                                                       // get rid of prefix 
and suffix, they are not eval-d correctly
+                                                       text = 
text.replace(/^\n\/\*<!\[CDATA\[\*\/\n/, "");
+                                                       text = 
text.replace(/\n\/\*\]\]>\*\/\n$/, "");
+                                                       
                                                        try {
                                                                
Wicket.Ajax._currentSuspension = suspension;
 
-                                                               // serialize 
the element content to string
-                                                               var text = 
Wicket.DOM.serializeNodeChildren(node);
-                                                               // get rid of 
prefix and suffix, they are not eval-d correctly
-                                                               text = 
text.replace(/^\n\/\*<!\[CDATA\[\*\/\n/, "");
-                                                               text = 
text.replace(/\n\/\*\]\]>\*\/\n$/, "");
                                                                
scriptDomNode.innerHTML = text;
 
                                                                var id = 
node.getAttribute("id");
-                                                               
Wicket.Head.addElement(scriptDomNode, typeof(id) !== "string" || id.length == 
0);
+                                                               
Wicket.Head.addElement(scriptDomNode, typeof(id) !== "string" || id.length === 
0);
                                                        } catch (exception) {
-                                                               
log.error("Ajax.Call.processEvaluation: Exception evaluating javascript: %s", 
text, exception);
+                                                               
Wicket.Log.error("Ajax.Call.processEvaluation: Exception evaluating javascript: 
%s", text, exception);
                                                        } finally {
                                                                
Wicket.Ajax.currentSuspension = undefined;
                                                        }
diff --git a/wicket-core/src/test/js/head.js b/wicket-core/src/test/js/head.js
index 0fcf8a8..8e9c231 100644
--- a/wicket-core/src/test/js/head.js
+++ b/wicket-core/src/test/js/head.js
@@ -15,7 +15,7 @@
  * limitations under the License.
  */
 
-/*global ok: true, start: true, test: true, equal: true, deepEqual: true,
+/*global ok: true, start: true, asyncTest: true, test: true, equal: true, 
deepEqual: true,
  QUnit: true, module: true, expect: true */
 
 jQuery(document).ready(function() {

Reply via email to