()
| 261 | |
| 262 | // Returns true if user is signed-in. Otherwise false and displays a message. |
| 263 | function checkSignedInWithMessage() { |
| 264 | // Return true if the user is signed in Firebase |
| 265 | if (isUserSignedIn()) { |
| 266 | return true; |
| 267 | } |
| 268 | |
| 269 | // Display a message to the user using a Toast. |
| 270 | var data = { |
| 271 | message: 'You must sign-in first', |
| 272 | timeout: 2000 |
| 273 | }; |
| 274 | signInSnackbarElement.MaterialSnackbar.showSnackbar(data); |
| 275 | return false; |
| 276 | } |
| 277 | |
| 278 | // Resets the given MaterialTextField. |
| 279 | function resetMaterialTextfield(element) { |
no test coverage detected