Skip to content

Commit 45f0d3f

Browse files
committed
Lint fixes
1 parent 34c2a39 commit 45f0d3f

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

server/runtime_javascript_nakama.go

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -403,36 +403,36 @@ func (n *runtimeJavascriptNakamaModule) storageIndexList(r *goja.Runtime) func(g
403403
objects := make([]any, 0, len(objectList.Objects))
404404
for _, o := range objectList.Objects {
405405
obj := r.NewObject()
406-
obj.Set("key", o.Key)
407-
obj.Set("collection", o.Collection)
406+
_ = obj.Set("key", o.Key)
407+
_ = obj.Set("collection", o.Collection)
408408
if o.UserId != "" {
409-
obj.Set("userId", o.UserId)
409+
_ = obj.Set("userId", o.UserId)
410410
} else {
411-
obj.Set("userId", nil)
411+
_ = obj.Set("userId", nil)
412412
}
413-
obj.Set("version", o.Version)
414-
obj.Set("permissionRead", o.PermissionRead)
415-
obj.Set("permissionWrite", o.PermissionWrite)
416-
obj.Set("createTime", o.CreateTime.Seconds)
417-
obj.Set("updateTime", o.UpdateTime.Seconds)
413+
_ = obj.Set("version", o.Version)
414+
_ = obj.Set("permissionRead", o.PermissionRead)
415+
_ = obj.Set("permissionWrite", o.PermissionWrite)
416+
_ = obj.Set("createTime", o.CreateTime.Seconds)
417+
_ = obj.Set("updateTime", o.UpdateTime.Seconds)
418418

419419
valueMap := make(map[string]interface{})
420420
err = json.Unmarshal([]byte(o.Value), &valueMap)
421421
if err != nil {
422422
panic(r.NewGoError(fmt.Errorf("failed to convert value to json: %s", err.Error())))
423423
}
424424
pointerizeSlices(valueMap)
425-
obj.Set("value", valueMap)
425+
_ = obj.Set("value", valueMap)
426426

427427
objects = append(objects, obj)
428428
}
429429

430430
outObj := r.NewObject()
431-
outObj.Set("objects", r.NewArray(objects...))
431+
_ = outObj.Set("objects", r.NewArray(objects...))
432432
if newCursor != "" {
433-
outObj.Set("cursor", newCursor)
433+
_ = outObj.Set("cursor", newCursor)
434434
} else {
435-
outObj.Set("cursor", goja.Null())
435+
_ = outObj.Set("cursor", goja.Null())
436436
}
437437

438438
return r.ToValue(outObj)

0 commit comments

Comments
 (0)