Skip to content

Commit

Permalink
Merge pull request #1720 from GSA-TTS/main
Browse files Browse the repository at this point in the history
2023-08-03 main -> prod #5
  • Loading branch information
tadhg-ohiggins authored Aug 4, 2023
2 parents f32e26f + 2684bd3 commit 13234de
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion backend/static/js/csrft.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
export const getCookie = () => {
return document.querySelector('[name=csrfmiddlewaretoken]').value;
const csrfInput = document.querySelector('[name=csrfmiddlewaretoken]');
if (csrfInput !== null) {
return document.querySelector('[name=csrfmiddlewaretoken]').value;
}
return null;
};

0 comments on commit 13234de

Please sign in to comment.