mirror of https://gitee.com/bigwinds/arangodb
fixed jslint warnings
This commit is contained in:
parent
42c6644749
commit
9f87ef5c17
|
@ -36,6 +36,7 @@ var RequestContext,
|
||||||
createBubbleWrap;
|
createBubbleWrap;
|
||||||
|
|
||||||
createBubbleWrap = function (handler, errorClass, code, reason, errorHandler) {
|
createBubbleWrap = function (handler, errorClass, code, reason, errorHandler) {
|
||||||
|
'use strict';
|
||||||
if (is.notExisty(errorHandler)) {
|
if (is.notExisty(errorHandler)) {
|
||||||
errorHandler = function () {
|
errorHandler = function () {
|
||||||
return { error: reason };
|
return { error: reason };
|
||||||
|
@ -58,19 +59,23 @@ createBubbleWrap = function (handler, errorClass, code, reason, errorHandler) {
|
||||||
|
|
||||||
// Wraps the docs object of a route to add swagger compatible documentation
|
// Wraps the docs object of a route to add swagger compatible documentation
|
||||||
SwaggerDocs = function (docs) {
|
SwaggerDocs = function (docs) {
|
||||||
|
'use strict';
|
||||||
this.docs = docs;
|
this.docs = docs;
|
||||||
};
|
};
|
||||||
|
|
||||||
extend(SwaggerDocs.prototype, {
|
extend(SwaggerDocs.prototype, {
|
||||||
addNickname: function (httpMethod, match) {
|
addNickname: function (httpMethod, match) {
|
||||||
|
'use strict';
|
||||||
this.docs.nickname = internal.constructNickname(httpMethod, match);
|
this.docs.nickname = internal.constructNickname(httpMethod, match);
|
||||||
},
|
},
|
||||||
|
|
||||||
addPathParam: function (paramName, description, dataType) {
|
addPathParam: function (paramName, description, dataType) {
|
||||||
|
'use strict';
|
||||||
this.docs.parameters.push(internal.constructPathParamDoc(paramName, description, dataType));
|
this.docs.parameters.push(internal.constructPathParamDoc(paramName, description, dataType));
|
||||||
},
|
},
|
||||||
|
|
||||||
addQueryParam: function (paramName, description, dataType, required, allowMultiple) {
|
addQueryParam: function (paramName, description, dataType, required, allowMultiple) {
|
||||||
|
'use strict';
|
||||||
this.docs.parameters.push(internal.constructQueryParamDoc(
|
this.docs.parameters.push(internal.constructQueryParamDoc(
|
||||||
paramName,
|
paramName,
|
||||||
description,
|
description,
|
||||||
|
@ -81,10 +86,12 @@ extend(SwaggerDocs.prototype, {
|
||||||
},
|
},
|
||||||
|
|
||||||
addSummary: function (summary) {
|
addSummary: function (summary) {
|
||||||
|
'use strict';
|
||||||
this.docs.summary = summary;
|
this.docs.summary = summary;
|
||||||
},
|
},
|
||||||
|
|
||||||
addNotes: function (notes) {
|
addNotes: function (notes) {
|
||||||
|
'use strict';
|
||||||
this.docs.notes = notes;
|
this.docs.notes = notes;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue