mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2026-01-09 17:04:30 +08:00
optional chaining
This commit is contained in:
parent
16c7750a01
commit
4582c3bdad
2 changed files with 3 additions and 3 deletions
|
|
@ -18,7 +18,7 @@ type AxiosClientMethods = AxiosClientMethod & AxiosClientDataMethod;
|
|||
async function adaptRequestOptions(
|
||||
options: Ape.RequestOptions
|
||||
): Promise<AxiosRequestConfig> {
|
||||
const currentUser = Auth.currentUser;
|
||||
const currentUser = Auth?.currentUser;
|
||||
const idToken = currentUser && (await getIdToken(currentUser));
|
||||
|
||||
return {
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ export async function show(): Promise<void> {
|
|||
"easeOutCubic"
|
||||
);
|
||||
|
||||
if (Auth.currentUser) {
|
||||
if (Auth?.currentUser) {
|
||||
$("#alertsPopup .accountAlerts").removeClass("hidden");
|
||||
$("#alertsPopup .separator.accountSeparator").removeClass("hidden");
|
||||
$("#alertsPopup .accountAlerts .list").html(`
|
||||
|
|
@ -134,7 +134,7 @@ export async function show(): Promise<void> {
|
|||
},
|
||||
100,
|
||||
() => {
|
||||
if (Auth.currentUser) {
|
||||
if (Auth?.currentUser) {
|
||||
getAccountAlerts();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue