diff options
author | Johan Preynat <johan.preynat@gmail.com> | 2016-05-02 14:05:11 +0200 |
---|---|---|
committer | Johan Preynat <johan.preynat@gmail.com> | 2016-05-02 14:05:11 +0200 |
commit | 429431c13c24606d9f9b8be97bec740350d622c0 (patch) | |
tree | 844d5c6a5f56fbf8edbc3752942343435596668a /lib/api | |
parent | b80dfd7b9a41b03f0bc30895c300deba54df8d6b (diff) | |
download | gitbook-429431c13c24606d9f9b8be97bec740350d622c0.zip gitbook-429431c13c24606d9f9b8be97bec740350d622c0.tar.gz gitbook-429431c13c24606d9f9b8be97bec740350d622c0.tar.bz2 |
lib/api/deprecate.js: Fix deprecateRenameMethod()
Diffstat (limited to 'lib/api')
-rw-r--r-- | lib/api/deprecate.js | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/api/deprecate.js b/lib/api/deprecate.js index 95ab93b..7a93a91 100644 --- a/lib/api/deprecate.js +++ b/lib/api/deprecate.js @@ -110,9 +110,7 @@ function deprecateRenamedMethod(book, key, instance, oldName, newName, msg) { msg = msg || ('"' + oldName + '" is deprecated, use "' + newName + '()" instead'); var fn = objectPath.get(instance, newName); - instance[oldName] = deprecateMethod(book, key, function() { - return fn.apply(instance, arguments); - }. msg); + instance[oldName] = deprecateMethod(book, key, fn, msg); } module.exports = { |