Skip to content

Commit 060d44b

Browse files
cassiobotarosideshow
authored andcommitted
Fix some lint errors (#121)
* gofmt -s * fix golint warnings about function commentary * ineffectual assignment to err (ineffassign)
1 parent d95b0d6 commit 060d44b

File tree

3 files changed

+4
-5
lines changed

3 files changed

+4
-5
lines changed

payload/builder.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ func (p *Payload) AlertActionLocKey(key string) *Payload {
237237
return p
238238
}
239239

240-
// SummaryArg sets the aps alert summary arg key on the payload.
240+
// AlertSummaryArg sets the aps alert summary arg key on the payload.
241241
// This is the string that is used as a key to fill in an argument
242242
// at the bottom of a notification to provide more context, such as
243243
// a name associated with the sender of the notification.
@@ -248,7 +248,7 @@ func (p *Payload) AlertSummaryArg(key string) *Payload {
248248
return p
249249
}
250250

251-
// SummaryArgCount sets the aps alert summary arg count key on the payload.
251+
// AlertSummaryArgCount sets the aps alert summary arg count key on the payload.
252252
// This integer sets a custom "weight" on the notification, effectively
253253
// allowing a notification to be viewed internally as two. For example if
254254
// a notification encompasses 3 messages, you can set it to 3.

payload/builder_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ func TestAlertSummaryArgCount(t *testing.T) {
187187
b, _ := json.Marshal(payload)
188188
assert.Equal(t, `{"aps":{"alert":{"summary-arg-count":3}}}`, string(b))
189189
}
190-
190+
191191
func TestCombined(t *testing.T) {
192192
payload := NewPayload().Alert("hello").Badge(1).Sound("Default.caf").Custom("key", "val")
193193
b, _ := json.Marshal(payload)

token/token_test.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,7 @@ func TestGenerateWithNoAuthKey(t *testing.T) {
8686

8787
func TestGenerateWithInvalidAuthKey(t *testing.T) {
8888
pubkeyCurve := elliptic.P521()
89-
privatekey, err := ecdsa.GenerateKey(pubkeyCurve, rand.Reader)
90-
89+
privatekey, _ := ecdsa.GenerateKey(pubkeyCurve, rand.Reader)
9190
token := &token.Token{
9291
AuthKey: privatekey,
9392
}

0 commit comments

Comments
 (0)