style: 合入后修 gofmt/govet 与 RegistrationView 类型检查

This commit is contained in:
Nixevol
2026-09-30 16:34:33 +08:00
parent 8f2ebc7d21
commit 0c9b459fb1
18 changed files with 74 additions and 79 deletions
+3 -3
View File
@@ -302,9 +302,9 @@ func (a *App) ReceiptAck(ctx context.Context, endpointID string, req *protocol.R
}
var acked bool
err = a.db.Queue.Do(ctx, func(tx *sql.Tx) error {
res, err := tx.Exec(`UPDATE receipts SET acked = 1 WHERE receipt_id = ? AND sender_id = ? AND acked = 0`, rid, endpointID)
if err != nil {
return err
res, execErr := tx.Exec(`UPDATE receipts SET acked = 1 WHERE receipt_id = ? AND sender_id = ? AND acked = 0`, rid, endpointID)
if execErr != nil {
return execErr
}
aff, _ := res.RowsAffected()
acked = aff > 0