diff --git a/pywb/rewrite/regex_rewriters.py b/pywb/rewrite/regex_rewriters.py index 69dbef32..686ad632 100644 --- a/pywb/rewrite/regex_rewriters.py +++ b/pywb/rewrite/regex_rewriters.py @@ -93,7 +93,7 @@ if (!self.__WB_pmw) {{ self.__WB_pmw = function(obj) {{ return obj; }} }}\n\ rules = [ (r'(?<=\.)postMessage\b\(', self.add_prefix('__WB_pmw(self).'), 0), - (r'(?>> _test_js_obj_proxy('return this.foo') 'return this.foo' +>>> _test_js_obj_proxy(r'this.$location = http://example.com/') +'this.$location = http://example.com/' + +>>> _test_js_obj_proxy(r'this. $location = http://example.com/') +'this. $location = http://example.com/' + +>>> _test_js_obj_proxy(r'this. _location = http://example.com/') +'this. _location = http://example.com/' + +>>> _test_js_obj_proxy(r'this. alocation = http://example.com/') +'this. alocation = http://example.com/' + +>>> _test_js_obj_proxy(r'this. location = http://example.com/') +'this. location = (self.__WB_check_loc && self.__WB_check_loc(location) || {}).href = http://example.com/' + + #================================================================= # XML Rewriting