From 47e0857a46a69d01a077bfec9cd195b236c622c5 Mon Sep 17 00:00:00 2001 From: Fredrik Jonsson <frjo@xdeb.org> Date: Thu, 5 Dec 2019 13:31:01 +0100 Subject: [PATCH] Replace jquery cookie with js-cookie lib that is used throughout the site and is maintained. --- .../templates/funds/applicationsubmission_admin_detail.html | 1 - opentech/static_src/src/javascript/apply/edit-comment.js | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/opentech/apply/funds/templates/funds/applicationsubmission_admin_detail.html b/opentech/apply/funds/templates/funds/applicationsubmission_admin_detail.html index 4fcf1fc15..1b007bcbb 100644 --- a/opentech/apply/funds/templates/funds/applicationsubmission_admin_detail.html +++ b/opentech/apply/funds/templates/funds/applicationsubmission_admin_detail.html @@ -65,7 +65,6 @@ {{ partner_form.media.js }} {{ block.super }} <script src="//cdnjs.cloudflare.com/ajax/libs/fancybox/3.4.1/jquery.fancybox.min.js"></script> - <script src="//cdnjs.cloudflare.com/ajax/libs/jquery-cookie/1.4.1/jquery.cookie.min.js"></script> <script src="{% static 'js/apply/fancybox-global.js' %}"></script> <script src="{% static 'js/apply/toggle-actions-panel.js' %}"></script> <script src="{% static 'js/apply/toggle-reviewers.js' %}"></script> diff --git a/opentech/static_src/src/javascript/apply/edit-comment.js b/opentech/static_src/src/javascript/apply/edit-comment.js index 3b7c3d88d..1153847ed 100644 --- a/opentech/static_src/src/javascript/apply/edit-comment.js +++ b/opentech/static_src/src/javascript/apply/edit-comment.js @@ -67,7 +67,7 @@ method: 'POST', headers: { 'Content-Type': 'application/json', - 'X-CSRFToken': $.cookie('csrftoken') + 'X-CSRFToken': window.Cookies.get('csrftoken') }, body: JSON.stringify({ message: editedComment -- GitLab