Skip to content

Commit

Permalink
Merge pull request #33 from pkwong4321/main
Browse files Browse the repository at this point in the history
fix(service):  Fix chat-id parsing in AddReceivers function
  • Loading branch information
nikoksr authored Feb 7, 2021
2 parents 29b64fe + 1cd7365 commit 04cf3c1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion service/telegram/telegram.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ func New(apiToken string) (*Telegram, error) {
func (t *Telegram) AddReceivers(chatIDs ...string) {
for _, v := range chatIDs {
chatID, err := strconv.ParseInt(v, 10, 64)
if err != nil {
if err == nil {
t.chatIDs = append(t.chatIDs, chatID)
}
}
Expand Down

0 comments on commit 04cf3c1

Please sign in to comment.