From b0b5253f66f5ba6e031f5a88dc1bef613517b3b6 Mon Sep 17 00:00:00 2001 From: Georgios Andreadis Date: Thu, 26 Jan 2017 23:26:20 +0100 Subject: Refactor remaining codebase to use 'const' --- src/scripts/profile.entry.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/scripts/profile.entry.ts') diff --git a/src/scripts/profile.entry.ts b/src/scripts/profile.entry.ts index 57c6b56c..b194e3a9 100644 --- a/src/scripts/profile.entry.ts +++ b/src/scripts/profile.entry.ts @@ -6,14 +6,14 @@ window["jQuery"] = $; $(document).ready(() => { - let api = new APIController(() => { + const api = new APIController(() => { }); $("#delete-account").on("click", () => { - let modalDialog = $("#confirm-delete-account"); + const modalDialog = $("#confirm-delete-account"); // Function called on delete confirmation - let callback = () => { + const callback = () => { api.deleteUser(parseInt(localStorage.getItem("userId"))).then(() => { removeUserInfo(); gapi.auth2.getAuthInstance().signOut().then(() => { @@ -23,7 +23,7 @@ $(document).ready(() => { modalDialog.find("button.confirm").off(); modalDialog.modal("hide"); - let alert = $(".account-delete-alert"); + const alert = $(".account-delete-alert"); alert.find("code").text(reason.code + ": " + reason.description); alert.slideDown(200); -- cgit v1.2.3