From eb5ef558a20a665bd017b7043b01beb72c4f946a Mon Sep 17 00:00:00 2001 From: Cindy Jiang Date: Fri, 30 Aug 2024 13:42:24 -0400 Subject: [PATCH 1/4] project 1A complete --- .mocharc.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.mocharc.yml b/.mocharc.yml index 16d8518d1b..b9246aa609 100644 --- a/.mocharc.yml +++ b/.mocharc.yml @@ -1,4 +1,4 @@ reporter: dot timeout: 25000 exit: true -bail: true +bail: false From 2b8bcf73b491ae6da1c52fe3c00adede90c3fd8a Mon Sep 17 00:00:00 2001 From: Cindy Jiang Date: Thu, 5 Sep 2024 13:29:58 -0400 Subject: [PATCH 2/4] public/src/client/account/header.js: emitRemoveCover function create --- public/src/client/account/header.js | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/public/src/client/account/header.js b/public/src/client/account/header.js index dfa888120b..ad71e5e212 100644 --- a/public/src/client/account/header.js +++ b/public/src/client/account/header.js @@ -153,18 +153,22 @@ define('forum/account/header', [ return; } - socket.emit('user.removeCover', { - uid: ajaxify.data.uid, - }, function (err) { - if (!err) { - ajaxify.refresh(); - } else { - alerts.error(err); - } - }); + emitRemoveCover(); }); }); } + function emitRemoveCover() { + socket.emit('user.removeCover', { + uid: ajaxify.data.uid, + }, function (err) { + if (!err) { + ajaxify.refresh(); + } else { + alerts.error(err); + } + }); + } + return AccountHeader; }); From 176d170e2d13d80488ce1b728446dd89a86bb02f Mon Sep 17 00:00:00 2001 From: Cindy Jiang Date: Thu, 5 Sep 2024 15:19:34 -0400 Subject: [PATCH 3/4] log add --- public/src/client/account/header.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/src/client/account/header.js b/public/src/client/account/header.js index ad71e5e212..c7cbdebff7 100644 --- a/public/src/client/account/header.js +++ b/public/src/client/account/header.js @@ -152,7 +152,7 @@ define('forum/account/header', [ if (!confirm) { return; } - + console.log('I made edit here to call on a helper function emitRemoveCover() instead of using nested functions.'); emitRemoveCover(); }); }); From d06e263209d813b2d1bccf40cd54d5f3a5cd76bc Mon Sep 17 00:00:00 2001 From: Cindy Jiang Date: Thu, 5 Sep 2024 19:25:16 -0400 Subject: [PATCH 4/4] project 1B complete --- public/src/client/account/header.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/src/client/account/header.js b/public/src/client/account/header.js index c7cbdebff7..406853a11d 100644 --- a/public/src/client/account/header.js +++ b/public/src/client/account/header.js @@ -152,7 +152,7 @@ define('forum/account/header', [ if (!confirm) { return; } - console.log('I made edit here to call on a helper function emitRemoveCover() instead of using nested functions.'); + console.log('Cindy Jiang'); emitRemoveCover(); }); });