mirror of
https://github.com/element-hq/dendrite.git
synced 2025-09-13 21:02:25 +03:00
mas: minor fixes in cross_signing_keys_table files
This commit is contained in:
parent
803cce882f
commit
7ffb2c1d81
2 changed files with 6 additions and 6 deletions
|
@ -45,8 +45,8 @@ const upsertCrossSigningKeysForUserSQL = "" +
|
|||
|
||||
const updateMasterCrossSigningKeyAllowReplacementWithoutUiaSQL = "" +
|
||||
"UPDATE keyserver_cross_signing_keys" +
|
||||
" SET updatable_without_uia_before_ms = $3" +
|
||||
" WHERE user_id = $1 AND key_type = $2"
|
||||
" SET updatable_without_uia_before_ms = $1" +
|
||||
" WHERE user_id = $2 AND key_type = $3"
|
||||
|
||||
type crossSigningKeysStatements struct {
|
||||
db *sql.DB
|
||||
|
@ -150,7 +150,7 @@ func (s *crossSigningKeysStatements) UpsertCrossSigningKeysForUser(
|
|||
func (s *crossSigningKeysStatements) UpdateMasterCrossSigningKeyAllowReplacementWithoutUIA(ctx context.Context, txn *sql.Tx, userID string, duration time.Duration) (int64, error) {
|
||||
keyTypeInt, _ := types.KeyTypePurposeToInt[fclient.CrossSigningKeyPurposeMaster]
|
||||
ts := time.Now().Add(duration).UnixMilli()
|
||||
result, err := sqlutil.TxStmt(txn, s.updateMasterCrossSigningKeyAllowReplacementWithoutUiaStmt).ExecContext(ctx, userID, keyTypeInt, ts)
|
||||
result, err := sqlutil.TxStmt(txn, s.updateMasterCrossSigningKeyAllowReplacementWithoutUiaStmt).ExecContext(ctx, ts, userID, keyTypeInt)
|
||||
if err != nil {
|
||||
return -1, err
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue