ref: replace "ctx.from.language_code" with a function to get the lang… #51

Merged
GiovaniFZ merged 2 commits from set_types into main 2025-05-03 00:08:13 +00:00
GiovaniFZ commented 2025-05-01 19:26:06 +00:00 (Migrated from github.com)

…uage code and fix ts implementation for "reply_to_message_id"

…uage code and fix ts implementation for "reply_to_message_id"
ihatenodejs (Migrated from github.com) requested changes 2025-05-02 16:42:09 +00:00
ihatenodejs (Migrated from github.com) left a comment

Great work! Thanks so much for your contribution, Giv, especially with how busy you are!

I made two quick comments for you to review, then I think it's good to go!

Great work! Thanks so much for your contribution, Giv, especially with how busy you are! I made two quick comments for you to review, then I think it's good to go!
ihatenodejs (Migrated from github.com) commented 2025-05-02 16:40:13 +00:00

You might have forgot to go back to this

You might have forgot to go back to this
@ -3,2 +5,4 @@
const reply_to_message_id = replyToMessageId(ctx);
if (!userInput || (verifyNaN && isNaN(Number(userInput)))) {
ctx.reply(message, {
parse_mode: "Markdown",
ihatenodejs (Migrated from github.com) commented 2025-05-02 16:36:35 +00:00

Do we have any consensus on the isNaN? I'm not sure why it was used.

Comment from code:
// not sure why isNaN is used here, but the input should be a number

Do we have any consensus on the `isNaN`? I'm not sure why it was used. Comment from code: `// not sure why isNaN is used here, but the input should be a number`
lucmsilva651 (Migrated from github.com) reviewed 2025-05-02 16:47:22 +00:00
@ -3,2 +5,4 @@
const reply_to_message_id = replyToMessageId(ctx);
if (!userInput || (verifyNaN && isNaN(Number(userInput)))) {
ctx.reply(message, {
parse_mode: "Markdown",
lucmsilva651 (Migrated from github.com) commented 2025-05-02 16:47:22 +00:00

EDIT: it is not tho, never messed with verifyInput

The isNaN thing is my fault I think, but I don't really know why I put it there... See some diffs to confirm, please!

EDIT: it is not tho, never messed with verifyInput The isNaN thing is my fault I think, but I don't really know why I put it there... See some diffs to confirm, please!
GiovaniFZ (Migrated from github.com) reviewed 2025-05-02 17:26:53 +00:00
GiovaniFZ (Migrated from github.com) commented 2025-05-02 17:26:53 +00:00

sadly this part is returning an error, I need to check why and what to do in this specific situation

sadly this part is returning an error, I need to check why and what to do in this specific situation
GiovaniFZ (Migrated from github.com) reviewed 2025-05-02 17:27:22 +00:00
GiovaniFZ (Migrated from github.com) commented 2025-05-02 17:27:22 +00:00

also this part should be refactored imo

also this part should be refactored imo
ihatenodejs commented 2025-05-03 00:07:05 +00:00 (Migrated from github.com)

I'm going to close and merge this now to make it easier for me to fix some of these issues. @GiovaniFZ Can you start making branches in the TelegramBot repo so it's easier to make changes without making a PR to your repo?

I'm going to close and merge this now to make it easier for me to fix some of these issues. @GiovaniFZ Can you start making branches in the `TelegramBot` repo so it's easier to make changes without making a PR to your repo?
Sign in to join this conversation.
No description provided.