Skip to content
Closed
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
8 changes: 3 additions & 5 deletions lib/model.js
Original file line number Diff line number Diff line change
Expand Up @@ -429,14 +429,12 @@ module.exports = function(registry) {
/**
* Disable remote invocation for the method with the given name.
*
* @param {String} name The name of the method.
* @param {Boolean} isStatic Is the method static (eg. `MyModel.myMethod`)? Pass
* `false` if the method defined on the prototype (eg.
* `MyModel.prototype.myMethod`).
* @param {String} name The name of the method (include `prototype.` if the method is defined on the prototype).
*
*/

Model.disableRemoteMethod = function(name, isStatic) {
this.sharedClass.disableMethod(name, isStatic || false);
this.sharedClass.disableMethodByName(name);
this.emit('remoteMethodDisabled', this.sharedClass, name);
};

Expand Down