From 652a66e3d1e0ceb11f79b1424a5eccbe878df544 Mon Sep 17 00:00:00 2001 From: Joe Flynn Date: Fri, 14 Nov 2014 14:11:23 -0500 Subject: [PATCH] ensure storage is writable when setting support flag. fixes #6755 --- assets/js/frontend/cart-fragments.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/assets/js/frontend/cart-fragments.js b/assets/js/frontend/cart-fragments.js index d2f6cd5a619..956cc6505c1 100644 --- a/assets/js/frontend/cart-fragments.js +++ b/assets/js/frontend/cart-fragments.js @@ -8,6 +8,9 @@ jQuery( function( $ ) { /** Cart Handling */ try { $supports_html5_storage = ( 'sessionStorage' in window && window.sessionStorage !== null ); + + window.sessionStorage.setItem( 'wc', 'test' ); + window.sessionStorage.removeItem( 'wc' ); } catch( err ) { $supports_html5_storage = false; }