Skip to content

Commit

Permalink
Add redirectTo for email password reset (#83)
Browse files Browse the repository at this point in the history
* Add redirectTo for email password reset

* format document

---------

Co-authored-by: dshukertjr <[email protected]>
  • Loading branch information
domhel and dshukertjr authored Apr 13, 2024
1 parent b3454fa commit 36bd5fa
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/src/components/supa_email_auth.dart
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,10 @@ class _SupaEmailAuthState extends State<SupaEmailAuth> {
});

final email = _emailController.text.trim();
await supabase.auth.resetPasswordForEmail(email);
await supabase.auth.resetPasswordForEmail(
email,
redirectTo: widget.redirectTo,
);
widget.onPasswordResetEmailSent?.call();
} on AuthException catch (error) {
widget.onError?.call(error);
Expand Down

0 comments on commit 36bd5fa

Please sign in to comment.