Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/security/Security.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ Security.prototype.fetchRole = function (id, options, cb) {

self.kuzzle.callbackRequired('Security.fetchRole', cb);

self.kuzzle.query(this.buildQueryArgs('fetchRole'), data, options, function (err, response) {
self.kuzzle.query(this.buildQueryArgs('getRole'), data, options, function (err, response) {
cb(err, err ? undefined : new Role(self, response.result._id, response.result._source));
});
};
Expand Down Expand Up @@ -248,7 +248,7 @@ Security.prototype.fetchProfile = function (id, options, cb) {

self.kuzzle.callbackRequired('Security.fetchProfile', cb);

self.kuzzle.query(this.buildQueryArgs('fetchProfile'), data, options, function (error, response) {
self.kuzzle.query(this.buildQueryArgs('getProfile'), data, options, function (error, response) {
cb(error, error ? undefined : new Profile(self, response.result._id, response.result._source));
});
};
Expand Down Expand Up @@ -439,7 +439,7 @@ Security.prototype.fetchUser = function (id, options, cb) {

self.kuzzle.callbackRequired('Security.fetchUser', cb);

self.kuzzle.query(this.buildQueryArgs('fetchUser'), data, options, function (err, response) {
self.kuzzle.query(this.buildQueryArgs('getUser'), data, options, function (err, response) {
cb(err, err ? undefined : new User(self, response.result._id, response.result._source));
});
};
Expand Down
2 changes: 1 addition & 1 deletion test/security/kuzzleSecurity/profilesMethods.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ describe('Security profiles methods', function () {
}
};
expectedQuery = {
action: 'fetchProfile',
action: 'getProfile',
controller: 'security',
_id: 'foobar'
};
Expand Down
2 changes: 1 addition & 1 deletion test/security/kuzzleSecurity/rolesMethods.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ describe('Security roles methods', function () {
error = null;
result = { result: {_id: 'foobar', _source: {} }};
expectedQuery = {
action: 'fetchRole',
action: 'getRole',
controller: 'security',
_id: 'foobar'
};
Expand Down
2 changes: 1 addition & 1 deletion test/security/kuzzleSecurity/userMethods.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ describe('Security user methods', function () {
error = null;
result = { result: {_id: 'foobar', _source: {profileIds: ['profile']}}};
expectedQuery = {
action: 'fetchUser',
action: 'getUser',
controller: 'security',
_id: 'foobar'
};
Expand Down