mirror of
https://github.com/ascribe/onion.git
synced 2025-01-03 10:25:08 +01:00
fix extraction
This commit is contained in:
parent
ee6d2789ed
commit
1b210bd10c
@ -1,6 +1,7 @@
|
|||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
import { sanitize } from './general_utils';
|
import { sanitize } from './general_utils';
|
||||||
|
import AppConstants from './constants_utils';
|
||||||
|
|
||||||
// TODO: Create Unittests that test all functions
|
// TODO: Create Unittests that test all functions
|
||||||
|
|
||||||
@ -67,7 +68,7 @@ export function getCookie(name) {
|
|||||||
let parts = document.cookie.split(';');
|
let parts = document.cookie.split(';');
|
||||||
|
|
||||||
for(let i = 0; i < parts.length; i++) {
|
for(let i = 0; i < parts.length; i++) {
|
||||||
if(parts[i].indexOf('csrftoken=') > -1) {
|
if(parts[i].indexOf(AppConstants.csrftoken + '=') > -1) {
|
||||||
return parts[i].split('=').pop();
|
return parts[i].split('=').pop();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user