diff --git a/flow.go b/flow.go index 334beaf..a6db508 100644 --- a/flow.go +++ b/flow.go @@ -69,7 +69,7 @@ func (f *KeycardFlow) Resume(params FlowParams) error { func (f *KeycardFlow) Cancel() error { prevState := f.state - if prevState != Idle { + if prevState == Idle { return errors.New("cannot cancel idle flow") }