fix(auth): prevent concurrent sendCodeSilently and add edge case tests

This commit is contained in:
qzl
2026-02-26 10:46:16 +08:00
parent 175da2a8b7
commit 8e8bcfa4f5
2 changed files with 59 additions and 1 deletions
@@ -167,7 +167,7 @@ class RegisterCubit extends Cubit<RegisterState> {
}
Future<void> sendCodeSilently() async {
if (!state.isStep1Valid) return;
if (!state.isStep1Valid || state.isSending) return;
emit(state.copyWith(isSending: true));