diff --git a/components/script/webdriver_handlers.rs b/components/script/webdriver_handlers.rs index a4014a699d9..700a15cde7e 100644 --- a/components/script/webdriver_handlers.rs +++ b/components/script/webdriver_handlers.rs @@ -300,10 +300,10 @@ pub fn handle_execute_script( global.evaluate_js_on_global_with_result( &eval, rval.handle_mut(), - ScriptFetchOptions::default_classic_script(&global), + ScriptFetchOptions::default_classic_script(global), global.api_base_url(), ); - jsval_to_webdriver(*cx, &window.upcast::(), rval.handle()) + jsval_to_webdriver(*cx, window.upcast::(), rval.handle()) }; reply.send(result).unwrap(); @@ -330,7 +330,7 @@ pub fn handle_execute_async_script( global.evaluate_js_on_global_with_result( &eval, rval.handle_mut(), - ScriptFetchOptions::default_classic_script(&global), + ScriptFetchOptions::default_classic_script(global), global.api_base_url(), ); }, @@ -1048,7 +1048,7 @@ pub fn handle_get_css( let element = node.downcast::().unwrap(); Ok(String::from( window - .GetComputedStyle(&element, None) + .GetComputedStyle(element, None) .GetPropertyValue(DOMString::from(name)), )) }), @@ -1173,7 +1173,7 @@ pub fn handle_is_enabled( ) { reply .send( - find_node_by_unique_id(&documents, pipeline, element_id).and_then(|node| match node + find_node_by_unique_id(documents, pipeline, element_id).and_then(|node| match node .downcast::( ) { Some(element) => Ok(element.enabled_state()), diff --git a/components/script/window_named_properties.rs b/components/script/window_named_properties.rs index 0140bd7c46e..bf0d384e3cd 100644 --- a/components/script/window_named_properties.rs +++ b/components/script/window_named_properties.rs @@ -142,7 +142,7 @@ unsafe extern "C" fn get_own_property_descriptor( &mut *is_none, ); } - return true; + true } #[allow(unsafe_code)]