Skip to content

Commit 8cb7008

Browse files
committed
bugfix: KuzzleDocument.publish now complies to Kuzzle 0.6 API
1 parent 0c30ca0 commit 8cb7008

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "kuzzle-sdk",
3-
"version": "1.0.8",
3+
"version": "1.0.9",
44
"description": "Official Javascript SDK for Kuzzle",
55
"author": "The Kuzzle Team <[email protected]>",
66
"repository": {

src/kuzzleDocument.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ KuzzleDocument.prototype.publish = function (options) {
295295

296296
data.persist = false;
297297

298-
this.kuzzle.query(this.collection, 'write', 'create', data, options);
298+
this.kuzzle.query(this.collection, 'write', 'publish', data, options);
299299

300300
return this;
301301
};

test/kuzzleDocument/methods.test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -404,7 +404,7 @@ describe('KuzzleDocument methods', function () {
404404
error = null;
405405
expectedQuery = {
406406
collection: 'foo',
407-
action: 'create',
407+
action: 'publish',
408408
controller: 'write',
409409
body: {}
410410
};

0 commit comments

Comments
 (0)