jQuery.Deferred exception: The string did not match the expected pattern
问题 I've a little headache with this console error, ONLY on Safari (working on MacBook actually). I have this function: function exists(element){ var exists = document.querySelector(element); return exists; } invoked inside another function: function includeHoverStylesheet(){ var path = $("body").attr("data-hover"); if (!("ontouchstart" in document.documentElement || exists("link[href='" + path + "'"))) { var link = document.createElement("link"); link.rel = "stylesheet", link.href = path,