From a68fc7a3a2558de28670e8865d60e1e49aee7d55 Mon Sep 17 00:00:00 2001 From: Vladyslav Tymofeiev <“vladyslavty@softwareplanetgroup.com”> Date: Wed, 21 Aug 2024 17:44:16 +0300 Subject: [PATCH] Set cookie value ror hideElements before redirect --- lms/static/js/student_account/views/FinishAuthView.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lms/static/js/student_account/views/FinishAuthView.js b/lms/static/js/student_account/views/FinishAuthView.js index ac09152c828..461516b6e12 100644 --- a/lms/static/js/student_account/views/FinishAuthView.js +++ b/lms/static/js/student_account/views/FinishAuthView.js @@ -76,11 +76,11 @@ render: function() { try { - var next = _.bind(this.enrollment, this); - this.checkEmailOptIn(next); if (this.hideElements) { document.cookie = 'hideElements=' + this.hideElements + '; path=/'; } + var next = _.bind(this.enrollment, this); + this.checkEmailOptIn(next); } catch (err) { this.updateTaskDescription(gettext('Error') + ': ' + err.message); this.redirect(this.nextUrl);