diff --git a/resources/lib/jquery.cookie/jquery.cookie.js b/resources/lib/jquery.cookie/jquery.cookie.js index dffdb5ccb3d..5be1cd4f461 100644 --- a/resources/lib/jquery.cookie/jquery.cookie.js +++ b/resources/lib/jquery.cookie/jquery.cookie.js @@ -16,7 +16,13 @@ } function decoded(s) { - return unRfc2068(decodeURIComponent(s.replace(pluses, ' '))); + try { + return unRfc2068(decodeURIComponent(s.replace(pluses, ' '))); + } catch(e) { + // If the cookie cannot be decoded this should not throw an error. + // See T271838. + return ''; + } } function unRfc2068(value) {