From f90be41094f358a220425ff8a1bd4ba4bfb725e7 Mon Sep 17 00:00:00 2001 From: boogiedk Date: Sun, 15 Oct 2023 16:47:58 +0300 Subject: [PATCH] fix --- SerfBot/TelegramBot.fs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/SerfBot/TelegramBot.fs b/SerfBot/TelegramBot.fs index 843dddd..1ac137b 100644 --- a/SerfBot/TelegramBot.fs +++ b/SerfBot/TelegramBot.fs @@ -10,8 +10,9 @@ open SerfBot.Types open SerfBot.TelegramApi let extractCommand (str: string) = - let command = (str.Split(" ")[0]).Trim().ToLower() - let userMessage = (str.Split(" ")[1]).Trim().ToLower() + let message = str.Split(" "); + let command = message[0].Trim().ToLower() + let userMessage = str.Split(" ")[1] (command, userMessage) let isValidUser (userId: int64) =