[MediaWiki-commits] [Gerrit] Shorten overly long lines - change (mediawiki...WikibaseJavaScriptApi)

2014-11-26 Thread WMDE
Thiemo Mättig (WMDE) has submitted this change and it was merged.

Change subject: Shorten overly long lines
..


Shorten overly long lines

Change-Id: I0dde5d6251420bf43636a1e8e0f19f44592aa7e7
---
M .jshintrc
M src/FormatValueCaller.js
M src/ParseValueCaller.js
M src/RepoApi.js
M tests/RepoApi.tests.js
5 files changed, 19 insertions(+), 11 deletions(-)

Approvals:
  Thiemo Mättig (WMDE): Verified; Looks good to me, approved



diff --git a/.jshintrc b/.jshintrc
index e1e7c3e..a5afa4d 100644
--- a/.jshintrc
+++ b/.jshintrc
@@ -50,7 +50,7 @@
 
"indent": 4,
"quotmark": false,
-   "maxlen": 110,
+   "maxlen": 100,
"maxparams": 7,
"maxdepth": 4,
"maxstatements": 19,
diff --git a/src/FormatValueCaller.js b/src/FormatValueCaller.js
index 9836a1f..0f44558 100644
--- a/src/FormatValueCaller.js
+++ b/src/FormatValueCaller.js
@@ -31,9 +31,9 @@
_dataTypeStore: null,
 
/**
-* Makes a request to the API to format values on the server 
side. Will return a jQuery.Promise
-* which will be resolved if formatting is successful or 
rejected if it fails or the API cannot
-* be reached.
+* Makes a request to the API to format values on the server 
side. Will return a
+* jQuery.Promise which will be resolved if formatting is 
successful or rejected if it fails
+* or the API cannot be reached.
 * @since 0.5
 *
 * @param {dataValues.DataValue} dataValue
diff --git a/src/ParseValueCaller.js b/src/ParseValueCaller.js
index 07cb134..01f06b4 100644
--- a/src/ParseValueCaller.js
+++ b/src/ParseValueCaller.js
@@ -28,7 +28,8 @@
 
/**
 * Makes a request to the API to parse values on the server side. Will 
return a jQuery.Promise
-* which will be resolved if the call is successful or rejected if the 
API fails or can't be reached.
+* which will be resolved if the call is successful or rejected if the 
API fails or can't be
+* reached.
 * @since 0.5
 *
 * @param {string} parser
@@ -61,8 +62,8 @@
 
if( result.error ) {
// This is a really strange error 
format, and it's not supported by
-   // 
wikibase.api.RepoApiError.newFromApiResponse, so we have to parse it manually 
here.
-   // See bug 72947.
+   // 
wikibase.api.RepoApiError.newFromApiResponse, so we have to parse it manually
+   // here. See bug 72947.
deferred.reject( new 
wb.api.RepoApiError(
result.messages[0].name,
result.messages[0].html['*']
@@ -71,7 +72,10 @@
}
 
if( !( result.value && result.type ) ) {
-   deferred.reject( new 
wb.api.RepoApiError( 'result-unexpected', 'Unknown API error' ) );
+   deferred.reject( new 
wb.api.RepoApiError(
+   'result-unexpected',
+   'Unknown API error'
+   ) );
return;
}
 
diff --git a/src/RepoApi.js b/src/RepoApi.js
index 8b09a27..4baf3f8 100644
--- a/src/RepoApi.js
+++ b/src/RepoApi.js
@@ -316,7 +316,7 @@
/**
 * Removes an existing claim.
 *
-* @param {String} claimGuid The GUID of the Claim to be removed 
(wikibase.datamodel.Claim.getGuid)
+* @param {String} claimGuid The GUID of the Claim to be removed
 * @param {Number} [claimRevisionId]
 * @return {jQuery.Promise}
 */
@@ -356,7 +356,7 @@
/**
 * Changes the Main Snak of an existing claim.
 *
-* @param {string} claimGuid The GUID of the Claim to be changed 
(wikibase.datamodel.Claim.getGuid)
+* @param {string} claimGuid The GUID of the Claim to be changed
 * @param {number} baseRevId
 * @param {string} snakType The type of the snak
 * @param {string} property Id of the snak's property
diff --git a/tests/RepoApi.tests.js b/tests/RepoApi.tests.js
index 0ae19f5..e59aa83 100644
--- a/tests/RepoApi.tests.js
+++ b/tests/RepoApi.tests.js
@@ -454,7 +454,11 @@
 
testrun.queue( qkey, function() {
api.setAliases(
-   entityStack[0].id, entityStack[0].lastrevid, [ 
'alias1', 'alias2' ], [], 'doesnotexist'
+   entityStack[0].id,
+

[MediaWiki-commits] [Gerrit] Shorten overly long lines - change (mediawiki...WikibaseJavaScriptApi)

2014-11-26 Thread Adrian Lang (Code Review)
Adrian Lang has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/175996

Change subject: Shorten overly long lines
..

Shorten overly long lines

Change-Id: I0dde5d6251420bf43636a1e8e0f19f44592aa7e7
---
M .jshintrc
M src/FormatValueCaller.js
M src/ParseValueCaller.js
M src/RepoApi.js
M tests/RepoApi.tests.js
5 files changed, 19 insertions(+), 11 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikibaseJavaScriptApi 
refs/changes/96/175996/1

diff --git a/.jshintrc b/.jshintrc
index e1e7c3e..a5afa4d 100644
--- a/.jshintrc
+++ b/.jshintrc
@@ -50,7 +50,7 @@
 
"indent": 4,
"quotmark": false,
-   "maxlen": 110,
+   "maxlen": 100,
"maxparams": 7,
"maxdepth": 4,
"maxstatements": 19,
diff --git a/src/FormatValueCaller.js b/src/FormatValueCaller.js
index 9836a1f..0f44558 100644
--- a/src/FormatValueCaller.js
+++ b/src/FormatValueCaller.js
@@ -31,9 +31,9 @@
_dataTypeStore: null,
 
/**
-* Makes a request to the API to format values on the server 
side. Will return a jQuery.Promise
-* which will be resolved if formatting is successful or 
rejected if it fails or the API cannot
-* be reached.
+* Makes a request to the API to format values on the server 
side. Will return a
+* jQuery.Promise which will be resolved if formatting is 
successful or rejected if it fails
+* or the API cannot be reached.
 * @since 0.5
 *
 * @param {dataValues.DataValue} dataValue
diff --git a/src/ParseValueCaller.js b/src/ParseValueCaller.js
index 07cb134..01f06b4 100644
--- a/src/ParseValueCaller.js
+++ b/src/ParseValueCaller.js
@@ -28,7 +28,8 @@
 
/**
 * Makes a request to the API to parse values on the server side. Will 
return a jQuery.Promise
-* which will be resolved if the call is successful or rejected if the 
API fails or can't be reached.
+* which will be resolved if the call is successful or rejected if the 
API fails or can't be
+* reached.
 * @since 0.5
 *
 * @param {string} parser
@@ -61,8 +62,8 @@
 
if( result.error ) {
// This is a really strange error 
format, and it's not supported by
-   // 
wikibase.api.RepoApiError.newFromApiResponse, so we have to parse it manually 
here.
-   // See bug 72947.
+   // 
wikibase.api.RepoApiError.newFromApiResponse, so we have to parse it manually
+   // here. See bug 72947.
deferred.reject( new 
wb.api.RepoApiError(
result.messages[0].name,
result.messages[0].html['*']
@@ -71,7 +72,10 @@
}
 
if( !( result.value && result.type ) ) {
-   deferred.reject( new 
wb.api.RepoApiError( 'result-unexpected', 'Unknown API error' ) );
+   deferred.reject( new 
wb.api.RepoApiError(
+   'result-unexpected',
+   'Unknown API error'
+   ) );
return;
}
 
diff --git a/src/RepoApi.js b/src/RepoApi.js
index 8b09a27..4baf3f8 100644
--- a/src/RepoApi.js
+++ b/src/RepoApi.js
@@ -316,7 +316,7 @@
/**
 * Removes an existing claim.
 *
-* @param {String} claimGuid The GUID of the Claim to be removed 
(wikibase.datamodel.Claim.getGuid)
+* @param {String} claimGuid The GUID of the Claim to be removed
 * @param {Number} [claimRevisionId]
 * @return {jQuery.Promise}
 */
@@ -356,7 +356,7 @@
/**
 * Changes the Main Snak of an existing claim.
 *
-* @param {string} claimGuid The GUID of the Claim to be changed 
(wikibase.datamodel.Claim.getGuid)
+* @param {string} claimGuid The GUID of the Claim to be changed
 * @param {number} baseRevId
 * @param {string} snakType The type of the snak
 * @param {string} property Id of the snak's property
diff --git a/tests/RepoApi.tests.js b/tests/RepoApi.tests.js
index 0ae19f5..e59aa83 100644
--- a/tests/RepoApi.tests.js
+++ b/tests/RepoApi.tests.js
@@ -454,7 +454,11 @@
 
testrun.queue( qkey, function() {
api.setAliases(
-   entityStack[0].id, entityStack[0].lastrevid, [ 
'alias1', 'alias2' ], [], 'doesnotexist'
+