aboutsummaryrefslogtreecommitdiff
path: root/userapi/storage/accounts/postgres/storage.go
diff options
context:
space:
mode:
Diffstat (limited to 'userapi/storage/accounts/postgres/storage.go')
-rw-r--r--userapi/storage/accounts/postgres/storage.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/userapi/storage/accounts/postgres/storage.go b/userapi/storage/accounts/postgres/storage.go
index 9d6fd13a..6bddbfc3 100644
--- a/userapi/storage/accounts/postgres/storage.go
+++ b/userapi/storage/accounts/postgres/storage.go
@@ -479,7 +479,7 @@ func (d *Database) UpsertBackupKeys(
err = d.keyBackups.updateBackupKey(ctx, txn, userID, version, newKey)
changed = true
if err != nil {
- return err
+ return fmt.Errorf("d.keyBackups.updateBackupKey: %w", err)
}
}
// if we shouldn't replace the key we do nothing with it
@@ -490,7 +490,7 @@ func (d *Database) UpsertBackupKeys(
err = d.keyBackups.insertBackupKey(ctx, txn, userID, version, newKey)
changed = true
if err != nil {
- return err
+ return fmt.Errorf("d.keyBackups.insertBackupKey: %w", err)
}
}