@dadi/api-wrapper
Advanced tools
Comparing version 1.1.1 to 1.1.2
@@ -335,8 +335,19 @@ module.exports = function (DadiAPI) { | ||
DadiAPI.prototype.withComposition = function (value) { | ||
value = (value !== false) | ||
this.compose = value !== false | ||
this._addToQuery('compose', value) | ||
return this | ||
} | ||
/** | ||
* Toggles the composition of all history revisions for the current document | ||
* | ||
* @param {Boolean} value | ||
* @return API | ||
* @api public | ||
*/ | ||
DadiAPI.prototype.includeHistory = function (value) { | ||
this.history = value !== false | ||
return this | ||
} | ||
} |
@@ -86,2 +86,10 @@ var passport = require('@dadi/passport') | ||
if (this.compose) { | ||
params.compose = this.compose | ||
} | ||
if (this.includeHistory) { | ||
params.includeHistory = this.history | ||
} | ||
if (this.sortField) { | ||
@@ -100,3 +108,2 @@ params.sort = this.sortField | ||
} | ||
return url | ||
@@ -103,0 +110,0 @@ } |
{ | ||
"name": "@dadi/api-wrapper", | ||
"version": "1.1.1", | ||
"version": "1.1.2", | ||
"description": "A high-level library for interacting with DADI API", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
26819
665