Only allow /help in private

This commit is contained in:
Michael De Roover 2021-05-08 18:45:04 +02:00
parent f592d7a8da
commit 03f23fa514
Signed by: vim
GPG Key ID: 075496E232CE04CB

View File

@ -79,6 +79,8 @@ debug(){
# Public commands # Public commands
help(){ help(){
if [ $(jq -r '.message.chat.type' <<< $input) == "private" ]
then
sendmsg "Hiya! I'm <a href=\"https://t.me/ghnou\">ghnou</a>'s personal bot, Konata. sendmsg "Hiya! I'm <a href=\"https://t.me/ghnou\">ghnou</a>'s personal bot, Konata.
<b>Currently I have the following features:</b> <b>Currently I have the following features:</b>
@ -96,6 +98,9 @@ help(){
- /repo - Get my source code. - /repo - Get my source code.
And a lot more to come!" And a lot more to come!"
else
sendmsg "Please ask me in <a href=\"https://t.me/$bot\">private</a>!"
fi
} }
alive(){ alive(){