Preparing report...

Report for gitlab.com/toby3d/telegram

A+    Excellent!    Found 13 issues across 24 files

Tweet

gofmt100%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command

No problems detected. Good job!


go_vet100%

go vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string.

No problems detected. Good job!


gocyclo100%

Gocyclo calculates cyclomatic complexities of functions in Go source code. The cyclomatic complexity of a function is calculated according to the following rules: 1 is the base complexity of a function +1 for each 'if', 'for', 'case', '&&' or '||' Go Report Card warns on functions with cyclomatic complexity > 15.

No problems detected. Good job!


golint50%

Golint is a linter for Go source code.

    • /gitlab.com/toby3d/telegram/errors.go
    • Line 9: warning: exported type Error should have comment or be unexported (golint)
    • Line 16: warning: exported method Error.FormatError should have comment or be unexported (golint)
    • Line 23: warning: exported method Error.Format should have comment or be unexported (golint)
    • /gitlab.com/toby3d/telegram/games.go
    • Line 43: warning: comment on exported type SendGame should be of the form "SendGame ..." (with optional leading article) (golint)
    • Line 66: warning: comment on exported type SetGameScore should be of the form "SetGameScore ..." (with optional leading article) (golint)
    • Line 91: warning: comment on exported type GetGameHighScores should be of the form "GetGameHighScores ..." (with optional leading article) (golint)
    • Line 107: warning: exported function NewGame should have comment or be unexported (golint)
    • Line 129: warning: exported function NewGameScore should have comment or be unexported (golint)
    • /gitlab.com/toby3d/telegram/inline.go
    • Line 905: warning: comment on exported type AnswerInlineQuery should be of the form "AnswerInlineQuery ..." (with optional leading article) (golint)
    • Line 935: warning: exported type ReplyMarkup should have comment or be unexported (golint)
    • Line 940: warning: exported function NewAnswerInline should have comment or be unexported (golint)
    • Line 963: warning: exported function NewReplyKeyboardRemove should have comment or be unexported (golint)
    • Line 970: warning: exported function NewInlineKeyboardButton should have comment or be unexported (golint)
    • Line 977: warning: exported function NewInlineKeyboardButtonSwitch should have comment or be unexported (golint)
    • Line 984: warning: exported function NewInlineKeyboardButtonSwitchSelf should have comment or be unexported (golint)
    • Line 991: warning: exported function NewInlineKeyboardButtonURL should have comment or be unexported (golint)
    • Line 998: warning: exported function NewInlineKeyboardMarkup should have comment or be unexported (golint)
    • Line 1002: warning: exported function NewInlineKeyboardRow should have comment or be unexported (golint)
    • Line 1006: warning: exported method InlineQuery.HasQuery should have comment or be unexported (golint)
    • Line 1008: warning: exported method InlineQuery.HasOffset should have comment or be unexported (golint)
    • Line 1010: warning: exported method InlineQuery.HasLocation should have comment or be unexported (golint)
    • Line 1012: warning: exported method ChosenInlineResult.HasLocation should have comment or be unexported (golint)
    • Line 1022: warning: exported function NewInlineQueryResultCachedAudio should have comment or be unexported (golint)
    • Line 1030: warning: exported method InlineQueryResultCachedAudio.IsCached should have comment or be unexported (golint)
    • Line 1032: warning: exported function NewInlineQueryResultCachedDocument should have comment or be unexported (golint)
    • Line 1041: warning: exported method InlineQueryResultCachedDocument.IsCached should have comment or be unexported (golint)
    • Line 1043: warning: exported function NewInlineQueryResultCachedGif should have comment or be unexported (golint)
    • Line 1051: warning: exported method InlineQueryResultCachedGif.IsCached should have comment or be unexported (golint)
    • Line 1053: warning: exported function NewInlineQueryResultCachedMpeg4Gif should have comment or be unexported (golint)
    • Line 1061: warning: exported method InlineQueryResultCachedMpeg4Gif.IsCached should have comment or be unexported (golint)
    • Line 1063: warning: exported function NewInlineQueryResultCachedPhoto should have comment or be unexported (golint)
    • Line 1071: warning: exported method InlineQueryResultCachedPhoto.IsCached should have comment or be unexported (golint)
    • Line 1073: warning: exported function NewInlineQueryResultCachedSticker should have comment or be unexported (golint)
    • Line 1081: warning: exported method InlineQueryResultCachedSticker.IsCached should have comment or be unexported (golint)
    • Line 1083: warning: exported function NewInlineQueryResultCachedVideo should have comment or be unexported (golint)
    • Line 1092: warning: exported method InlineQueryResultCachedVideo.IsCached should have comment or be unexported (golint)
    • Line 1094: warning: exported function NewInlineQueryResultCachedVoice should have comment or be unexported (golint)
    • Line 1103: warning: exported method InlineQueryResultCachedVoice.IsCached should have comment or be unexported (golint)
    • Line 1105: warning: exported function NewInlineQueryResultArticle should have comment or be unexported (golint)
    • Line 1114: warning: exported method InlineQueryResultArticle.IsCached should have comment or be unexported (golint)
    • Line 1116: warning: exported function NewInlineQueryResultAudio should have comment or be unexported (golint)
    • Line 1125: warning: exported method InlineQueryResultAudio.IsCached should have comment or be unexported (golint)
    • Line 1127: warning: exported function NewInlineQueryResultContact should have comment or be unexported (golint)
    • Line 1136: warning: exported method InlineQueryResultContact.IsCached should have comment or be unexported (golint)
    • Line 1138: warning: exported function NewInlineQueryResultGame should have comment or be unexported (golint)
    • Line 1146: warning: exported method InlineQueryResultGame.IsCached should have comment or be unexported (golint)
    • Line 1148: warning: exported function NewInlineQueryResultDocument should have comment or be unexported (golint)
    • Line 1158: warning: exported method InlineQueryResultDocument.IsCached should have comment or be unexported (golint)
    • Line 1160: warning: exported function NewInlineQueryResultGif should have comment or be unexported (golint)
    • Line 1169: warning: exported method InlineQueryResultGif.IsCached should have comment or be unexported (golint)
    • Line 1171: warning: exported function NewInlineQueryResultLocation should have comment or be unexported (golint)
    • Line 1181: warning: exported method InlineQueryResultLocation.IsCached should have comment or be unexported (golint)
    • Line 1183: warning: exported function NewInlineQueryResultMpeg4Gif should have comment or be unexported (golint)
    • Line 1192: warning: exported method InlineQueryResultMpeg4Gif.IsCached should have comment or be unexported (golint)
    • Line 1194: warning: exported function NewInlineQueryResultPhoto should have comment or be unexported (golint)
    • Line 1203: warning: exported method InlineQueryResultPhoto.IsCached should have comment or be unexported (golint)
    • Line 1205: warning: exported function NewInlineQueryResultVenue should have comment or be unexported (golint)
    • Line 1216: warning: exported method InlineQueryResultVenue.IsCached should have comment or be unexported (golint)
    • Line 1218: warning: exported function NewInlineQueryResultVideo should have comment or be unexported (golint)
    • Line 1229: warning: exported method InlineQueryResultVideo.IsCached should have comment or be unexported (golint)
    • Line 1231: warning: exported function NewInlineQueryResultVoice should have comment or be unexported (golint)
    • Line 1240: warning: exported method InlineQueryResultVoice.IsCached should have comment or be unexported (golint)
    • /gitlab.com/toby3d/telegram/types.go
    • Line 539: warning: comment on exported type PollOption should be of the form "PollOption ..." (with optional leading article) (golint)
    • Line 561: warning: comment on exported type Poll should be of the form "Poll ..." (with optional leading article) (golint)
    • Line 990: warning: exported type AlbumMedia should have comment or be unexported (golint)
    • Line 1144: warning: exported type Photo should have comment or be unexported (golint)
    • Line 1170: warning: comment on exported method User.HasLastName should be of the form "HasLastName ..." (golint)
    • Line 1173: warning: comment on exported method User.HasUsername should be of the form "HasUsername ..." (golint)
    • Line 1179: warning: comment on exported method User.IsForwarder should be of the form "IsForwarder ..." (golint)
    • Line 1213: warning: comment on exported method Chat.HasLastName should be of the form "HasLastName ..." (golint)
    • Line 1216: warning: comment on exported method Chat.HasUsername should be of the form "HasUsername ..." (golint)
    • Line 1219: warning: exported method Chat.HasDescription should have comment or be unexported (golint)
    • Line 1221: warning: exported method Chat.HasInviteLink should have comment or be unexported (golint)
    • Line 1456: warning: comment on exported method MessageEntity.IsPhoneNumber should be of the form "IsPhoneNumber ..." (golint)
    • Line 1462: warning: comment on exported method MessageEntity.IsStrikethrough should be of the form "IsStrikethrough ..." (golint)
    • Line 1509: warning: exported method Audio.FullName should have comment or be unexported (golint)
    • Line 1528: warning: exported method Audio.HasPerformer should have comment or be unexported (golint)
    • Line 1530: warning: exported method Audio.HasTitle should have comment or be unexported (golint)
    • Line 1532: warning: exported method Audio.HasThumb should have comment or be unexported (golint)
    • Line 1543: warning: exported method Document.HasThumb should have comment or be unexported (golint)
    • Line 1545: warning: exported method Document.File should have comment or be unexported (golint)
    • Line 1553: warning: exported method Video.HasThumb should have comment or be unexported (golint)
    • Line 1555: warning: exported method Video.File should have comment or be unexported (golint)
    • Line 1563: warning: exported method Animation.HasThumb should have comment or be unexported (golint)
    • Line 1565: warning: exported method Animation.File should have comment or be unexported (golint)
    • Line 1573: warning: exported method Voice.File should have comment or be unexported (golint)
    • Line 1581: warning: exported method VideoNote.HasThumb should have comment or be unexported (golint)
    • Line 1583: warning: exported method VideoNote.File should have comment or be unexported (golint)
    • Line 1604: warning: comment on exported method Contact.HasLastName should be of the form "HasLastName ..." (golint)
    • Line 1607: warning: exported method Contact.InTelegram should have comment or be unexported (golint)
    • Line 1609: warning: exported method Contact.HasVCard should have comment or be unexported (golint)
    • Line 1621: warning: exported method ChatPhoto.SmallFile should have comment or be unexported (golint)
    • Line 1628: warning: exported method ChatPhoto.BigFile should have comment or be unexported (golint)
    • Line 1653: warning: exported method InputMediaAnimation.GetMedia should have comment or be unexported (golint)
    • Line 1655: warning: exported method InputMediaAudio.GetMedia should have comment or be unexported (golint)
    • Line 1659: warning: exported method InputMediaDocument.GetMedia should have comment or be unexported (golint)
    • Line 1663: warning: exported method InputMediaPhoto.GetMedia should have comment or be unexported (golint)
    • Line 1667: warning: exported method InputMediaVideo.GetMedia should have comment or be unexported (golint)
    • Line 1671: warning: exported method InputFile.IsFileID should have comment or be unexported (golint)
    • Line 1673: warning: exported method InputFile.IsURI should have comment or be unexported (golint)
    • Line 1675: warning: exported method InputFile.IsAttachment should have comment or be unexported (golint)
    • /gitlab.com/toby3d/telegram/updates.go
    • Line 91: warning: comment on exported type GetUpdates should be of the form "GetUpdates ..." (with optional leading article) (golint)
    • Line 108: warning: comment on exported type SetWebhook should be of the form "SetWebhook ..." (with optional leading article) (golint)
    • Line 132: warning: exported type DeleteWebhook should have comment or be unexported (golint)
    • Line 271: warning: exported method WebhookInfo.LastErrorTime should have comment or be unexported (golint)
    • Line 273: warning: exported method WebhookInfo.HasURL should have comment or be unexported (golint)
    • Line 275: warning: exported method WebhookInfo.URI should have comment or be unexported (golint)
    • /gitlab.com/toby3d/telegram/methods.go
    • Line 197: warning: comment on exported type SendVideo should be of the form "SendVideo ..." (with optional leading article) (golint)
    • Line 941: warning: exported function NewMessage should have comment or be unexported (golint)
    • Line 963: warning: exported function NewForward should have comment or be unexported (golint)
    • Line 1002: warning: exported function NewPhoto should have comment or be unexported (golint)
    • Line 1046: warning: exported function NewAudio should have comment or be unexported (golint)
    • Line 1102: warning: exported function NewDocument should have comment or be unexported (golint)
    • Line 1145: warning: exported function NewVideo should have comment or be unexported (golint)
    • Line 1200: warning: exported function NewAnimation should have comment or be unexported (golint)
    • Line 1254: warning: exported function NewVoice should have comment or be unexported (golint)
    • Line 1298: warning: exported function NewVideoNote should have comment or be unexported (golint)
    • Line 1349: warning: exported function NewMediaGroup should have comment or be unexported (golint)
    • Line 1395: warning: exported function NewLocation should have comment or be unexported (golint)
    • Line 1418: warning: exported function NewLiveLocation should have comment or be unexported (golint)
    • Line 1455: warning: exported function NewVenue should have comment or be unexported (golint)
    • Line 1480: warning: exported function NewContact should have comment or be unexported (golint)
    • Line 1503: warning: exported function NewPoll should have comment or be unexported (golint)
    • Line 1596: warning: exported function NewKick should have comment or be unexported (golint)
    • Line 1643: warning: exported function NewRestrict should have comment or be unexported (golint)
    • Line 1651: warning: comment on exported method Bot.RestrictChatMember should be of the form "RestrictChatMember ..." (golint)
    • Line 1670: warning: exported function NewPromote should have comment or be unexported (golint)
    • Line 1908: warning: exported function NewPin should have comment or be unexported (golint)
    • Line 1953: warning: comment on exported method Bot.UnpinAllChatMessages should be of the form "UnpinAllChatMessages ..." (golint)
    • Line 2096: warning: exported function NewAnswerCallback should have comment or be unexported (golint)
    • /gitlab.com/toby3d/telegram/passport.go
    • Line 231: warning: exported type SetPassportDataErrors should have comment or be unexported (golint)
    • Line 239: warning: comment on exported type Auth should be of the form "Auth ..." (with optional leading article) (golint)
    • Line 298: warning: exported type Passport should have comment or be unexported (golint)
    • Line 528: warning: exported var ErrNotEqual should have comment or be unexported (golint)
    • /gitlab.com/toby3d/telegram/payments.go
    • Line 143: warning: comment on exported type SendInvoice should be of the form "SendInvoice ..." (with optional leading article) (golint)
    • Line 212: warning: comment on exported type AnswerShippingQuery should be of the form "AnswerShippingQuery ..." (with optional leading article) (golint)
    • Line 227: warning: comment on exported type AnswerPreCheckoutQuery should be of the form "AnswerPreCheckoutQuery ..." (with optional leading article) (golint)
    • Line 240: warning: exported function NewInvoice should have comment or be unexported (golint)
    • Line 269: warning: exported function NewAnswerShipping should have comment or be unexported (golint)
    • Line 292: warning: exported function NewAnswerPreCheckout should have comment or be unexported (golint)
    • /gitlab.com/toby3d/telegram/stickers.go
    • Line 78: warning: comment on exported type SendSticker should be of the form "SendSticker ..." (with optional leading article) (golint)
    • Line 98: warning: comment on exported type GetStickerSet should be of the form "GetStickerSet ..." (with optional leading article) (golint)
    • Line 104: warning: exported type UploadStickerFile should have comment or be unexported (golint)
    • Line 112: warning: exported type CreateNewStickerSet should have comment or be unexported (golint)
    • Line 139: warning: exported type AddStickerToSet should have comment or be unexported (golint)
    • Line 160: warning: comment on exported type SetStickerPositionInSet should be of the form "SetStickerPositionInSet ..." (with optional leading article) (golint)
    • Line 169: warning: comment on exported type DeleteStickerFromSet should be of the form "DeleteStickerFromSet ..." (with optional leading article) (golint)
    • Line 194: warning: exported function NewSticker should have comment or be unexported (golint)
    • Line 254: warning: exported function NewStickerSet should have comment or be unexported (golint)
    • Line 392: warning: exported method Sticker.HasThumb should have comment or be unexported (golint)
    • Line 394: warning: exported method Sticker.IsMask should have comment or be unexported (golint)
    • Line 396: warning: exported method Sticker.File should have comment or be unexported (golint)
    • /gitlab.com/toby3d/telegram/updating_messages.go
    • Line 4: warning: comment on exported type EditMessageText should be of the form "EditMessageText ..." (with optional leading article) (golint)
    • Line 30: warning: comment on exported type EditMessageCaption should be of the form "EditMessageCaption ..." (with optional leading article) (golint)
    • Line 53: warning: comment on exported type EditMessageMedia should be of the form "EditMessageMedia ..." (with optional leading article) (golint)
    • Line 70: warning: comment on exported type EditMessageReplyMarkup should be of the form "EditMessageReplyMarkup ..." (with optional leading article) (golint)
    • Line 84: warning: exported type StopPoll should have comment or be unexported (golint)
    • Line 94: warning: comment on exported type DeleteMessage should be of the form "DeleteMessage ..." (with optional leading article) (golint)
    • Line 103: warning: exported function NewEditText should have comment or be unexported (golint)
    • Line 137: warning: exported function NewEditMedia should have comment or be unexported (golint)
    • Line 173: warning: exported function NewStopPoll should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


misspell95%

Misspell Finds commonly misspelled English words