2
0
mirror of https://github.com/yagop/node-telegram-bot-api synced 2025-08-29 05:17:41 +00:00

[docs] Fix undocumented return value for TelegramBot#setWebHook()

This commit is contained in:
GochoMugo 2017-01-11 16:20:07 +03:00
parent 0d20565bd5
commit 0c18cda922
No known key found for this signature in database
GPG Key ID: 7B6A01CB57AA39E4
2 changed files with 3 additions and 2 deletions

View File

@ -79,7 +79,7 @@ TelegramBot
* [.closeWebHook()](#TelegramBot+closeWebHook) ⇒ <code>Promise</code> * [.closeWebHook()](#TelegramBot+closeWebHook) ⇒ <code>Promise</code>
* [.hasOpenWebHook()](#TelegramBot+hasOpenWebHook) ⇒ <code>Boolean</code> * [.hasOpenWebHook()](#TelegramBot+hasOpenWebHook) ⇒ <code>Boolean</code>
* [.getMe()](#TelegramBot+getMe) ⇒ <code>Promise</code> * [.getMe()](#TelegramBot+getMe) ⇒ <code>Promise</code>
* [.setWebHook(url, [options])](#TelegramBot+setWebHook) * [.setWebHook(url, [options])](#TelegramBot+setWebHook)<code>Promise</code>
* [.deleteWebHook()](#TelegramBot+deleteWebHook) ⇒ <code>Promise</code> * [.deleteWebHook()](#TelegramBot+deleteWebHook) ⇒ <code>Promise</code>
* [.getWebHookInfo()](#TelegramBot+getWebHookInfo) ⇒ <code>Promise</code> * [.getWebHookInfo()](#TelegramBot+getWebHookInfo) ⇒ <code>Promise</code>
* [.getUpdates([options])](#TelegramBot+getUpdates) ⇒ <code>Promise</code> * [.getUpdates([options])](#TelegramBot+getUpdates) ⇒ <code>Promise</code>
@ -216,7 +216,7 @@ Returns basic information about the bot in form of a `User` object.
**See**: https://core.telegram.org/bots/api#getme **See**: https://core.telegram.org/bots/api#getme
<a name="TelegramBot+setWebHook"></a> <a name="TelegramBot+setWebHook"></a>
### telegramBot.setWebHook(url, [options]) ### telegramBot.setWebHook(url, [options])<code>Promise</code>
Specify an url to receive incoming updates via an outgoing webHook. Specify an url to receive incoming updates via an outgoing webHook.
This method has an [older, compatible signature][setWebHook-v0.25.0] This method has an [older, compatible signature][setWebHook-v0.25.0]
that is being deprecated. that is being deprecated.

View File

@ -333,6 +333,7 @@ class TelegramBot extends EventEmitter {
* delete webHook. * delete webHook.
* @param {Object} [options] Additional Telegram query options * @param {Object} [options] Additional Telegram query options
* @param {String|stream.Stream} [options.certificate] PEM certificate key (public). * @param {String|stream.Stream} [options.certificate] PEM certificate key (public).
* @return {Promise}
* @see https://core.telegram.org/bots/api#setwebhook * @see https://core.telegram.org/bots/api#setwebhook
*/ */
setWebHook(url, options = {}) { setWebHook(url, options = {}) {