Skip to content

Commit

Permalink
chore: refactor 2 line
Browse files Browse the repository at this point in the history
  • Loading branch information
hglong16 authored Dec 12, 2023
1 parent 2cff5f4 commit ad85e0a
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -265,8 +265,11 @@ export function getPayloadTelegram(inputs: Readonly<TInputs>): Object {
parse_mode: 'MarkdownV2',
};

if (inputs.telegram_message_thread_id) {
telegram_payload.message_thread_id = inputs.telegram_message_thread_id;
if (inputs.telegram_message_thread_id !== "") {
telegram_payload = {
...telegram_payload,
message_thread_id: inputs.telegram_message_thread_id
}
}

return telegram_payload;
Expand Down

0 comments on commit ad85e0a

Please sign in to comment.