Hi guys,
We’re having an issue with the {{dc:cookie:get name=“isVet”}} condition on the front-end.
On desktop, it seemed to work as expected, but the behaviour was a bit inconsistent on mobile (debugging on iOS Safari). After some digging, we’re thinking it’s because the user was logged out of WordPress, as we got similar behaviour when testing on incognito. We can see that the cookie is there on dev tools, but for some reason this condition doesn’t kick in:
We have some Page JS that checks document.cookies, which is working as expected:
window.addEventListener(‘DOMContentLoaded’, () => {
// console.log(document.cookie);
if (!document.cookie.split(’;’).some(c => c.trim().startsWith(‘isVet=’))) {
if (window.location.hash !== ‘#access’) {
window.location.hash = ‘access’;
}
}
});
Weirdly, sometimes it worked when we added that console.log() statement above, but other times it didn’t, and we’re not sure why. Are there any known issues with dc:cookie:get, or any ideas of what could be causing this?
Thanks

