1
0
mirror of https://github.com/kha7iq/pingme.git synced 2025-05-15 22:30:11 -07:00

Merge pull request #49 from brenkem/fix-string-conversion

fix: use strconv.ParseInt instead of strconv.Atoi
This commit is contained in:
Khaliq 2021-06-21 23:10:32 +08:00 committed by GitHub
commit 24242b5da2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -78,11 +78,11 @@ All configuration options are also available via environment variables.`,
if len(v) <= 0 { if len(v) <= 0 {
return helpers.ErrChannel return helpers.ErrChannel
} }
k, errStr := strconv.Atoi(v) k, errStr := strconv.ParseInt(v, 10, 64)
if errStr != nil { if errStr != nil {
return errStr return errStr
} }
telegramSvc.AddReceivers(int64(k)) telegramSvc.AddReceivers(k)
} }
notifier.UseServices(telegramSvc) notifier.UseServices(telegramSvc)