update
This commit is contained in:
parent
f1db550ee7
commit
b2aeb642cc
11 changed files with 209 additions and 60 deletions
|
|
@ -1,28 +1,28 @@
|
|||
import 'package:supabase_flutter/supabase_flutter.dart';
|
||||
import 'package:pharmacy_mobile/main.dart';
|
||||
// import 'package:supabase_flutter/supabase_flutter.dart';
|
||||
// import 'package:pharmacy_mobile/main.dart';
|
||||
|
||||
Future<void> signUp() async {
|
||||
try {
|
||||
await supabase.auth.signUp(
|
||||
email: email,
|
||||
password: password,
|
||||
);
|
||||
// if (mounted) {
|
||||
// context.showSnackBar('Check your email for a login link!');
|
||||
// Future<void> signUp() async {
|
||||
// try {
|
||||
// await supabase.auth.signUp(
|
||||
// email: email,
|
||||
// password: password,
|
||||
// );
|
||||
// // if (mounted) {
|
||||
// // context.showSnackBar('Check your email for a login link!');
|
||||
|
||||
// _emailController.clear();
|
||||
// }
|
||||
} on AuthException catch (error) {
|
||||
if (mounted) context.showSnackBar(error.message, isError: true);
|
||||
} catch (error) {
|
||||
if (mounted) {
|
||||
context.showSnackBar('Unexpected error occurred', isError: true);
|
||||
}
|
||||
} finally {
|
||||
if (mounted) {
|
||||
setState(() {
|
||||
_isLoading = false;
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
// // _emailController.clear();
|
||||
// // }
|
||||
// } on AuthException catch (error) {
|
||||
// if (mounted) context.showSnackBar(error.message, isError: true);
|
||||
// } catch (error) {
|
||||
// if (mounted) {
|
||||
// context.showSnackBar('Unexpected error occurred', isError: true);
|
||||
// }
|
||||
// } finally {
|
||||
// if (mounted) {
|
||||
// setState(() {
|
||||
// _isLoading = false;
|
||||
// });
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue