Add parenthesis to functions to make sure that parameters used are those from the function call

This commit is contained in:
adrien 2021-02-09 10:25:47 +01:00
parent 6678e7ff92
commit 32405fcdcc

View File

@ -21,7 +21,7 @@ key=
# set your chat id here # set your chat id here
chat_id= chat_id=
function send_message { function send_message() {
if [ $# -eq 0 ] if [ $# -eq 0 ]
then then
echo "No argument supplied. Please specify the message to send." echo "No argument supplied. Please specify the message to send."
@ -30,7 +30,7 @@ function send_message {
fi fi
} }
function update_gitea { function update_gitea() {
systemctl stop gitea.service systemctl stop gitea.service
# download the latest version # download the latest version