This repository was archived by the owner on Apr 4, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +23
-2
lines changed Expand file tree Collapse file tree 2 files changed +23
-2
lines changed Original file line number Diff line number Diff line change 130
130
<Label row =" 12" col =" 1" text =" {{ userEmailOrPhone }}" class =" message" textWrap =" true" />
131
131
132
132
<Button row =" 13" col =" 0" text =" email login link" tap =" {{ doLoginByEmailLink }}" class =" button" />
133
- <Button row =" 13" col =" 1" text =" send email conf" tap =" {{ doSendEmailVerification }}" class =" button" />
133
+ <!-- <Button row="13" col="1" text="send email conf" tap="{{ doSendEmailVerification }}" class="button"/>-->
134
+ <Button row =" 13" col =" 1" text =" reload user" tap =" {{ doReloadUser }}" class =" button" />
134
135
135
136
<Button row =" 14" col =" 0" text =" get current user" tap =" {{ doGetCurrentUser }}" class =" button" />
136
137
<Button row =" 14" col =" 1" text =" logout" tap =" {{ doLogout }}" class =" button button-user" />
Original file line number Diff line number Diff line change @@ -1144,7 +1144,8 @@ export class HelloWorldModel extends Observable {
1144
1144
}
1145
1145
} ) . then (
1146
1146
result => {
1147
- console . log ( "Google login OK: " + JSON . stringify ( result ) ) ;
1147
+ console . log ( "Google login OK: " + JSON . stringify ( result . additionalUserInfo ) ) ;
1148
+ console . log ( "Google login OK, photoURL: " + result . photoURL ) ;
1148
1149
alert ( {
1149
1150
title : "Login OK" ,
1150
1151
message : JSON . stringify ( result ) ,
@@ -1161,6 +1162,25 @@ export class HelloWorldModel extends Observable {
1161
1162
) ;
1162
1163
}
1163
1164
1165
+ public doReloadUser ( ) : void {
1166
+ firebase . reloadUser ( ) . then (
1167
+ ( ) => {
1168
+ alert ( {
1169
+ title : "User reloaded" ,
1170
+ message : "You can use 'get current user' to inspect the reloaded data" ,
1171
+ okButtonText : "OK"
1172
+ } ) ;
1173
+ } ,
1174
+ errorMessage => {
1175
+ alert ( {
1176
+ title : "Reload error" ,
1177
+ message : errorMessage ,
1178
+ okButtonText : "OK, shame"
1179
+ } ) ;
1180
+ }
1181
+ ) ;
1182
+ }
1183
+
1164
1184
public doResetPassword ( ) : void {
1165
1185
firebase . sendPasswordResetEmail ( "eddyverbruggen+firebase@gmail.com" ) . then (
1166
1186
( ) => {
You can’t perform that action at this time.
0 commit comments