mirror of
https://github.com/abocn/TelegramBot.git
synced 2025-03-10 12:49:57 +00:00
Changed the order just for better code visual
This commit is contained in:
parent
abaecd4782
commit
67f8e5e34b
@ -5,6 +5,9 @@ const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(is
|
|||||||
async function sendHelpMessage(ctx, isEditing) {
|
async function sendHelpMessage(ctx, isEditing) {
|
||||||
const Strings = getStrings(ctx.from.language_code);
|
const Strings = getStrings(ctx.from.language_code);
|
||||||
const botInfo = await ctx.telegram.getMe();
|
const botInfo = await ctx.telegram.getMe();
|
||||||
|
const helpText = Strings.botHelp
|
||||||
|
.replace('{botName}', botInfo.first_name)
|
||||||
|
.replace("{sourceLink}", `${process.env.botSource}`);
|
||||||
const options = {
|
const options = {
|
||||||
parse_mode: 'Markdown',
|
parse_mode: 'Markdown',
|
||||||
disable_web_page_preview: true,
|
disable_web_page_preview: true,
|
||||||
@ -19,9 +22,6 @@ async function sendHelpMessage(ctx, isEditing) {
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
const helpText = Strings.botHelp
|
|
||||||
.replace('{botName}', botInfo.first_name)
|
|
||||||
.replace("{sourceLink}", `${process.env.botSource}`);
|
|
||||||
if (isEditing) {
|
if (isEditing) {
|
||||||
await ctx.editMessageText(helpText, options);
|
await ctx.editMessageText(helpText, options);
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user