summaryrefslogtreecommitdiff
path: root/src/scripts/profile.entry.ts
diff options
context:
space:
mode:
authorGeorgios Andreadis <g.andreadis@student.tudelft.nl>2017-01-26 23:26:20 +0100
committerGeorgios Andreadis <g.andreadis@student.tudelft.nl>2017-01-26 23:26:20 +0100
commitb0b5253f66f5ba6e031f5a88dc1bef613517b3b6 (patch)
treef764e84ad48de6cb514cbc97e366c21d734e247c /src/scripts/profile.entry.ts
parent027b379cf9d53a12782781e586f79051461ab661 (diff)
Refactor remaining codebase to use 'const'
Diffstat (limited to 'src/scripts/profile.entry.ts')
-rw-r--r--src/scripts/profile.entry.ts8
1 files changed, 4 insertions, 4 deletions
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 = <any>$("#confirm-delete-account");
+ const modalDialog = <any>$("#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);