Felipe Schenone has submitted this change and it was merged.

Change subject: Add JSHint
......................................................................


Add JSHint

- Add .jshintrc file for code quality
- Very minor fixes

Change-Id: I9a93a48487bf94e3bdf4b02bbbdf0446b102a461
---
A .jshintrc
M proveit.js
2 files changed, 24 insertions(+), 2 deletions(-)

Approvals:
  Felipe Schenone: Verified; Looks good to me, approved



diff --git a/.jshintrc b/.jshintrc
new file mode 100644
index 0000000..b9e5076
--- /dev/null
+++ b/.jshintrc
@@ -0,0 +1,22 @@
+{
+       // Enforcing
+       "bitwise": true,
+       "eqeqeq": true,
+       "esversion": 3,
+       "freeze": true,
+       "futurehostile": true,
+       "latedef": "nofunc",
+       "noarg": true,
+       "nonew": true,
+       "strict": false,
+       "undef": true,
+       "unused": true,
+
+       // Environment
+       "browser": true,
+
+       "globals": {
+               "mediaWiki": false,
+               "jQuery": false
+       }
+}
\ No newline at end of file
diff --git a/proveit.js b/proveit.js
index 9ee4a3c..d8273f5 100755
--- a/proveit.js
+++ b/proveit.js
@@ -351,7 +351,7 @@
                        'name': 'wpChangeTags',
                        'value': tag
                });
-               $( '#editform' ).append( tagInput );
+               $( '#editform' ).prepend( tagInput );
        },
 
        /**
@@ -662,7 +662,7 @@
                 * @return {object}
                 */
                this.getRegisteredParams = function () {
-                       var formattedNamespaces = mw.config.get( 
'wgFormattedNamespaces' );
+                       var formattedNamespaces = mw.config.get( 
'wgFormattedNamespaces' ),
                                templateNamespace = formattedNamespaces[10];
                        return proveit.templates[ templateNamespace + ':' + 
this.template ];
                };

-- 
To view, visit https://gerrit.wikimedia.org/r/305576
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I9a93a48487bf94e3bdf4b02bbbdf0446b102a461
Gerrit-PatchSet: 2
Gerrit-Project: wikipedia/gadgets/ProveIt
Gerrit-Branch: master
Gerrit-Owner: Felipe Schenone <scheno...@gmail.com>
Gerrit-Reviewer: Felipe Schenone <scheno...@gmail.com>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to