File tree Expand file tree Collapse file tree 1 file changed +17
-13
lines changed
frontend/src/app/settings Expand file tree Collapse file tree 1 file changed +17
-13
lines changed Original file line number Diff line number Diff line change @@ -63,19 +63,23 @@ const SettingPage = () => {
63
63
64
64
const onFormSubmit = ( e : React . FormEvent < HTMLFormElement > ) => {
65
65
e . preventDefault ( ) ;
66
- updateProfileUrl ( name , preferredLang , selectedImage ) . then ( ( res ) => {
67
- if ( res . statusMessage . type . toLowerCase ( ) === "success" ) {
68
- api . success ( {
69
- type : "success" ,
70
- content : "Successfully updated profile!" ,
71
- } ) ;
72
- } else {
73
- api . error ( {
74
- type : "error" ,
75
- content : "Failed to update profile :(" ,
76
- } ) ;
77
- }
78
- } ) ;
66
+ updateProfileUrl ( name , preferredLang , selectedImage )
67
+ . then ( ( res ) => {
68
+ if ( res . statusMessage . type . toLowerCase ( ) === "success" ) {
69
+ api . success ( {
70
+ type : "success" ,
71
+ content : "Successfully updated profile!" ,
72
+ } ) ;
73
+ } else {
74
+ api . error ( {
75
+ type : "error" ,
76
+ content : "Failed to update profile :(" ,
77
+ } ) ;
78
+ }
79
+ } )
80
+ . then ( ( ) => {
81
+ window . location . reload ( ) ;
82
+ } ) ;
79
83
} ;
80
84
81
85
const onEscKeyDown = ( e : React . KeyboardEvent < HTMLDialogElement > ) => {
You can’t perform that action at this time.
0 commit comments