Preparing report...

Report for github.com/blazingorb/sendbirdclient

A+    Excellent!    Found 14 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!


gocyclo91%

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.


golint41%

Golint is a linter for Go source code.

    • sendbirdclient/client.go
    • Line 13: warning: exported const SendbirdAPITokenHeaderKey should have comment (or a comment on this block) or be unexported (golint)
    • Line 196: warning: exported method Client.PrepareUrl should have comment or be unexported (golint)
    • sendbirdclient/groupchannels.go
    • Line 11: warning: exported type GroupChannel should have comment or be unexported (golint)
    • Line 22: warning: exported type LastMessage should have comment or be unexported (golint)
    • Line 32: warning: exported method Client.CreateAGroupChannelWithURL should have comment or be unexported (golint)
    • Line 42: warning: exported type CreateAGroupChannelWithURLRequest should have comment or be unexported (golint)
    • Line 51: warning: exported method Client.CreateAGroupChannelWithFile should have comment or be unexported (golint)
    • Line 55: warning: exported type CreateAGroupChannelWithFileRequest should have comment or be unexported (golint)
    • Line 64: warning: exported method Client.ListGroupChannels should have comment or be unexported (golint)
    • Line 143: warning: exported type ListGroupChannelsRequest should have comment or be unexported (golint)
    • Line 159: warning: exported type ListGroupChannelsResponse should have comment or be unexported (golint)
    • Line 164: warning: exported method Client.UpdateAGroupChannel should have comment or be unexported (golint)
    • Line 182: warning: exported type UpdateAGroupChannelRequest should have comment or be unexported (golint)
    • Line 190: warning: exported method Client.ViewAGroupChannel should have comment or be unexported (golint)
    • Line 223: warning: exported type ViewAGroupChannelRequest should have comment or be unexported (golint)
    • Line 228: warning: exported method Client.DeleteAGroupChannel should have comment or be unexported (golint)
    • Line 246: warning: exported method Client.ListMembersInGroupChannel should have comment or be unexported (golint)
    • Line 279: warning: exported type ListMembersInGroupChannelRequest should have comment or be unexported (golint)
    • Line 284: warning: exported type ListMembersInGroupChannelResponse should have comment or be unexported (golint)
    • Line 289: warning: exported method Client.CheckIfMemberInGroupChannel should have comment or be unexported (golint)
    • Line 310: warning: exported type CheckIfMemberInGroupChannelResponse should have comment or be unexported (golint)
    • Line 314: warning: exported method Client.InviteMembersToGroupChannel should have comment or be unexported (golint)
    • Line 332: warning: exported type InviteMembersToGroupChannelRequest should have comment or be unexported (golint)
    • Line 336: warning: exported method Client.HideFromAGroupChannel should have comment or be unexported (golint)
    • Line 354: warning: exported type HideFromAGroupChannelRequest should have comment or be unexported (golint)
    • Line 358: warning: exported method Client.LeaveFromAGroupChannel should have comment or be unexported (golint)
    • Line 376: warning: exported type LeaveFromAGroupChannelRequest should have comment or be unexported (golint)
    • sendbirdclient/usermeta.go
    • Line 15: warning: exported method Client.CreateAnUserMetaData should have comment or be unexported (golint)
    • Line 31: warning: exported type CreateAnUserMetaDataRequest should have comment or be unexported (golint)
    • Line 35: warning: exported method Client.ListUserMetaData should have comment or be unexported (golint)
    • Line 66: warning: exported type ListUserMetaDataRequest should have comment or be unexported (golint)
    • Line 70: warning: exported method Client.ViewAnUserMetaData should have comment or be unexported (golint)
    • Line 90: warning: exported method Client.UpdateUserMetaData should have comment or be unexported (golint)
    • Line 106: warning: exported type UpdateUserMetaDataRequest should have comment or be unexported (golint)
    • Line 111: warning: exported method Client.UpdateUserMetaDataItem should have comment or be unexported (golint)
    • Line 130: warning: exported type UpdateUserMetaDataItemRequest should have comment or be unexported (golint)
    • Line 135: warning: exported method Client.DeleteUserMetaData should have comment or be unexported (golint)
    • Line 152: warning: exported method Client.DeleteUserMetaDataItem should have comment or be unexported (golint)
    • sendbirdclient/channelmeta.go
    • Line 16: warning: exported method Client.CreateAChannelMetadata should have comment or be unexported (golint)
    • Line 36: warning: exported type CreateAChannelMetadataRequest should have comment or be unexported (golint)
    • Line 40: warning: exported method Client.ViewChannelMetadata should have comment or be unexported (golint)
    • Line 70: warning: exported type ViewChannelMetadataRequest should have comment or be unexported (golint)
    • Line 74: warning: exported method Client.ViewChannelMetadataByKeyName should have comment or be unexported (golint)
    • Line 91: warning: exported method Client.UpdateChannelMetaData should have comment or be unexported (golint)
    • Line 111: warning: exported type UpdateChannelMetaDataRequest should have comment or be unexported (golint)
    • Line 116: warning: exported method Client.UpdateChannelMetaDataByKeyName should have comment or be unexported (golint)
    • Line 137: warning: exported type UpdateChannelMetaDataByKeyNameRequest should have comment or be unexported (golint)
    • Line 142: warning: exported method Client.DeleteChannelMetaData should have comment or be unexported (golint)
    • Line 162: warning: exported method Client.DeleteChannelMetaDataByKeyName should have comment or be unexported (golint)
    • Line 183: warning: exported method Client.CreateChannelMetaCounter should have comment or be unexported (golint)
    • Line 203: warning: exported type CreateChannelMetaCounterRequest should have comment or be unexported (golint)
    • Line 207: warning: exported method Client.ViewChannelMetaCounter should have comment or be unexported (golint)
    • Line 237: warning: exported type ViewChannelMetaCounterRequest should have comment or be unexported (golint)
    • Line 241: warning: exported method Client.ViewChannelMetaCounterByKeyName should have comment or be unexported (golint)
    • Line 258: warning: exported method Client.UpdateChannelMetaCounter should have comment or be unexported (golint)
    • Line 274: warning: exported type UpdateChannelMetaCounterRequest should have comment or be unexported (golint)
    • Line 280: warning: exported method Client.UpdateChannelMetaCounterByKeyName should have comment or be unexported (golint)
    • Line 297: warning: exported type UpdateChannelMetaCounterByKeyNameRequest should have comment or be unexported (golint)
    • Line 303: warning: exported method Client.DeleteChannelMetaCounter should have comment or be unexported (golint)
    • Line 319: warning: exported method Client.DeleteChannelMetaCounterByKeyName should have comment or be unexported (golint)
    • sendbirdclient/user.go
    • Line 11: warning: exported type User should have comment or be unexported (golint)
    • Line 30: warning: exported method Client.CreateAUserWithURL should have comment or be unexported (golint)
    • Line 44: warning: exported type CreateAUserWithURLRequest should have comment or be unexported (golint)
    • Line 51: warning: exported method Client.CreateAUserWithFile should have comment or be unexported (golint)
    • Line 55: warning: exported type CreateAUserWithFileRequest should have comment or be unexported (golint)
    • Line 62: warning: exported method Client.ListUsers should have comment or be unexported (golint)
    • Line 104: warning: exported type ListUsersRequest should have comment or be unexported (golint)
    • Line 112: warning: exported type ListUsersResponse should have comment or be unexported (golint)
    • Line 117: warning: exported method Client.UpdateAUserWithURL should have comment or be unexported (golint)
    • Line 134: warning: exported type UpdateAUserWithURLRequest should have comment or be unexported (golint)
    • Line 142: warning: exported method Client.UpdateAUserWithFile should have comment or be unexported (golint)
    • Line 146: warning: exported type UpdateAUserWithFileRequest should have comment or be unexported (golint)
    • Line 154: warning: exported method Client.ViewAUser should have comment or be unexported (golint)
    • Line 171: warning: exported method Client.DeleteAUser should have comment or be unexported (golint)
    • Line 188: warning: exported method Client.GetUnreadMessageCount should have comment or be unexported (golint)
    • Line 205: warning: exported type GetUnreadMessageCountResponse should have comment or be unexported (golint)
    • Line 210: warning: exported method Client.BlockAUser should have comment or be unexported (golint)
    • Line 226: warning: exported type BlockAUserRequest should have comment or be unexported (golint)
    • Line 230: warning: exported method Client.ListBlockedUsers should have comment or be unexported (golint)
    • Line 261: warning: exported type ListBlockUsersRequest should have comment or be unexported (golint)
    • Line 266: warning: exported type ListBlockUsersResponse should have comment or be unexported (golint)
    • Line 271: warning: exported method Client.UnblockAUser should have comment or be unexported (golint)
    • Line 291: warning: exported method Client.ListBannedChannels should have comment or be unexported (golint)
    • Line 322: warning: exported type ListBannedChannelsRequest should have comment or be unexported (golint)
    • Line 327: warning: exported type ListBannedChannelsResponse should have comment or be unexported (golint)
    • Line 332: warning: exported type BannedChannelResult should have comment or be unexported (golint)
    • Line 339: warning: exported method Client.ListMutedChannels should have comment or be unexported (golint)
    • Line 370: warning: exported type ListMutedChannelsRequest should have comment or be unexported (golint)
    • Line 375: warning: exported type ListMutedChannelsResponse should have comment or be unexported (golint)
    • Line 381: warning: exported method Client.MarkAllMessagesAsRead should have comment or be unexported (golint)
    • Line 398: warning: exported method Client.ListMyGroupChannels should have comment or be unexported (golint)
    • Line 497: warning: exported type ListMyGroupChannelsRequest should have comment or be unexported (golint)
    • Line 515: warning: exported type ListMyGroupChannelsResponse should have comment or be unexported (golint)
    • Line 521: warning: exported method Client.RegisterADeviceToken should have comment or be unexported (golint)
    • Line 540: warning: exported type RegisterADeviceTokenRequest should have comment or be unexported (golint)
    • Line 545: warning: exported type RegisterADeviceTokenResponse should have comment or be unexported (golint)
    • Line 551: warning: exported method Client.UnregisterADeviceToken should have comment or be unexported (golint)
    • Line 572: warning: exported type UnregisterADeviceTokenResponse should have comment or be unexported (golint)
    • Line 577: warning: exported method Client.UnregisterAllDeviceTokens should have comment or be unexported (golint)
    • Line 594: warning: exported method Client.ListDeviceTokens should have comment or be unexported (golint)
    • Line 614: warning: exported type ListDeviceTokensResponse should have comment or be unexported (golint)
    • Line 620: warning: exported method Client.UpdatePushPerferences should have comment or be unexported (golint)
    • Line 636: warning: exported type UpdatePushPerferencesRequest should have comment or be unexported (golint)
    • Line 645: warning: exported type UpdatePushPerferencesResponse should have comment or be unexported (golint)
    • Line 655: warning: exported method Client.GetPushPerferences should have comment or be unexported (golint)
    • Line 672: warning: exported type GetPushPerferencesResponse should have comment or be unexported (golint)
    • Line 681: warning: exported method Client.ResetPushPerferences should have comment or be unexported (golint)
    • Line 698: warning: exported method Client.UpdateChannelPushPerferences should have comment or be unexported (golint)
    • Line 717: warning: exported type UpdateChannelPushPerferencesRequest should have comment or be unexported (golint)
    • Line 721: warning: exported type UpdateChannelPushPerferencesResponse should have comment or be unexported (golint)
    • Line 725: warning: exported method Client.GetChannelPushPerferences should have comment or be unexported (golint)
    • Line 745: warning: exported type GetChannelPushPerferencesResponse should have comment or be unexported (golint)
    • sendbirdclient/messages.go
    • Line 13: warning: exported type TextMessage should have comment or be unexported (golint)
    • Line 21: warning: exported type FileMessage should have comment or be unexported (golint)
    • Line 30: warning: exported type File should have comment or be unexported (golint)
    • Line 35: warning: exported type AdminMessage should have comment or be unexported (golint)
    • sendbirdclient/openchannels.go
    • Line 10: warning: exported type OpenChannel should have comment or be unexported (golint)
    • Line 25: warning: exported method Client.CreateAnOpenChannelWithURL should have comment or be unexported (golint)
    • Line 35: warning: exported type CreateAnOpenChannelWithURLRequest should have comment or be unexported (golint)
    • Line 44: warning: exported method Client.CreateAnOpenChannelWithFile should have comment or be unexported (golint)
    • Line 48: warning: exported type CreateAnOpenChannelWithFileRequest should have comment or be unexported (golint)
    • Line 57: warning: exported method Client.ListOpenChannels should have comment or be unexported (golint)
    • Line 86: warning: exported type ListOpenChannelsRequest should have comment or be unexported (golint)
    • Line 92: warning: exported type ListOpenChannelsResponse should have comment or be unexported (golint)
    • Line 97: warning: exported method Client.UpdateAnOpenChannelWithURL should have comment or be unexported (golint)
    • Line 114: warning: exported type UpdateAnOpenChannelWithURLRequest should have comment or be unexported (golint)
    • Line 122: warning: exported method Client.UpdateAnOpenChannelWithFile should have comment or be unexported (golint)
    • Line 126: warning: exported type UpdateAnOpenChannelWithFileRequest should have comment or be unexported (golint)
    • Line 134: warning: exported method Client.ViewAnOpenChannel should have comment or be unexported (golint)
    • Line 162: warning: exported type ViewAnOpenChannelRequest should have comment or be unexported (golint)
    • Line 166: warning: exported method Client.DeleteAnOpenChannel should have comment or be unexported (golint)
    • Line 183: warning: exported method Client.ListOpenChannelParticipants should have comment or be unexported (golint)
    • Line 215: warning: exported type ListOpenChannelParticipantsRequest should have comment or be unexported (golint)
    • Line 220: warning: exported type ListOpenChannelParticipantsResponse should have comment or be unexported (golint)
    • Line 225: warning: exported method Client.FreezeAnOpenChannel should have comment or be unexported (golint)
    • Line 242: warning: exported type FreezeAnOpenChannelRequest should have comment or be unexported (golint)
    • Line 246: warning: exported method Client.BanAUserInOpenChannel should have comment or be unexported (golint)
    • Line 263: warning: exported type BanAUserInOpenChannelRequest should have comment or be unexported (golint)
    • Line 270: warning: exported type BanAUserInOpenChannelResponse should have comment or be unexported (golint)
    • Line 278: warning: exported method Client.ListBannedUsersInOpenChannel should have comment or be unexported (golint)
    • Line 310: warning: exported type ListBannedUsersInOpenChannelRequest should have comment or be unexported (golint)
    • Line 315: warning: exported type ListBannedUsersInOpenChannelResponse should have comment or be unexported (golint)
    • Line 320: warning: exported type BannedResult should have comment or be unexported (golint)
    • Line 327: warning: exported method Client.UpdateBanInOpenChannel should have comment or be unexported (golint)
    • Line 347: warning: exported type UpdateBanInOpenChannelRequest should have comment or be unexported (golint)
    • Line 352: warning: exported method Client.ViewBanInOpenChannel should have comment or be unexported (golint)
    • Line 372: warning: exported method Client.UnbanAUserInOpenChannel should have comment or be unexported (golint)
    • Line 392: warning: exported method Client.MuteAUserInOpenChannel should have comment or be unexported (golint)
    • Line 408: warning: exported type MuteAUserInOpenChannelRequest should have comment or be unexported (golint)
    • Line 412: warning: exported method Client.ListMutedUsersInOpenChannel should have comment or be unexported (golint)
    • Line 443: warning: exported type ListMutedUsersInOpenChannelRequest should have comment or be unexported (golint)
    • Line 448: warning: exported type ListMutedUsersInOpenChannelResponse should have comment or be unexported (golint)
    • Line 453: warning: exported method Client.ViewAMuteInOpenChannel should have comment or be unexported (golint)
    • Line 472: warning: exported type ViewAMuteInOpenChannelResponse should have comment or be unexported (golint)
    • Line 476: warning: exported method Client.UnmuteAUserInOpenChannel should have comment or be unexported (golint)
    • sendbirdclient/templates/templater.go
    • Line 10: warning: exported function GetUsersTemplate should have comment or be unexported (golint)
    • Line 14: warning: exported function GetOpenChannelTemplate should have comment or be unexported (golint)
    • Line 18: warning: exported function GetGroupChannelTemplate should have comment or be unexported (golint)
    • Line 22: warning: exported function GetChannelMetadataTemplate should have comment or be unexported (golint)
    • Line 26: warning: exported function GetMessagesTemplate should have comment or be unexported (golint)
    • sendbirdclient/errors.go
    • Line 12: warning: exported const SendbirdAPIErrorUniqueIDConstraint should have comment (or a comment on this block) or be unexported (golint)
    • Line 37: warning: exported function CheckSendbirdError should have comment or be unexported (golint)
    • sendbirdclient/webhook.go
    • Line 14: warning: exported const WebhookCategoryOpenChannelMsgSend should have comment (or a comment on this block) or be unexported (golint)
    • Line 30: warning: exported type WebhookCallback should have comment or be unexported (golint)
    • Line 34: warning: exported type WebhookHelper should have comment or be unexported (golint)
    • Line 38: warning: exported method WebhookHelper.SendbirdWebhook should have comment or be unexported (golint)
    • Line 81: warning: exported method WebhookHelper.Subscribe should have comment or be unexported (golint)
    • Line 81: warning: receiver name h should be consistent with previous receiver name wh for WebhookHelper (golint)
    • Line 96: warning: exported function NewWebhookHelper should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign95%

IneffAssign detects ineffectual assignments in Go code.

    • sendbirdclient/channelmeta.go
    • Line 41: warning: ineffectual assignment to err (ineffassign)
    • Line 75: warning: ineffectual assignment to err (ineffassign)
    • Line 208: warning: ineffectual assignment to err (ineffassign)
    • Line 242: warning: ineffectual assignment to err (ineffassign)
    • Line 259: warning: ineffectual assignment to err (ineffassign)
    • Line 281: warning: ineffectual assignment to err (ineffassign)
    • Line 304: warning: ineffectual assignment to err (ineffassign)
    • Line 320: warning: ineffectual assignment to err (ineffassign)

misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!