mirror of
https://mau.dev/mautrix/go.git
synced 2026-03-14 14:25:53 +01:00
crypto/verification: include the incorrect state in non-ready error message
This commit is contained in:
parent
19153e3638
commit
931f89202b
1 changed files with 1 additions and 1 deletions
|
|
@ -46,7 +46,7 @@ func (vh *VerificationHelper) StartSAS(ctx context.Context, txnID id.Verificatio
|
|||
if err != nil {
|
||||
return fmt.Errorf("failed to get verification transaction %s: %w", txnID, err)
|
||||
} else if txn.VerificationState != VerificationStateReady {
|
||||
return errors.New("transaction is not in ready state")
|
||||
return fmt.Errorf("transaction is not in ready state: %s", txn.VerificationState.String())
|
||||
} else if txn.StartEventContent != nil {
|
||||
return errors.New("start event already sent or received")
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue