mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
clippy: Fix let_and_return warnings (#31964)
This commit is contained in:
parent
0da2508e4d
commit
c7b73e1ef4
8 changed files with 17 additions and 31 deletions
|
@ -50,14 +50,13 @@ pub struct MediaSession {
|
|||
impl MediaSession {
|
||||
#[allow(crown::unrooted_must_root)]
|
||||
fn new_inherited() -> MediaSession {
|
||||
let media_session = MediaSession {
|
||||
MediaSession {
|
||||
reflector_: Reflector::new(),
|
||||
metadata: DomRefCell::new(None),
|
||||
playback_state: DomRefCell::new(MediaSessionPlaybackState::None),
|
||||
action_handlers: DomRefCell::new(HashMapTracedValues::new()),
|
||||
media_instance: Default::default(),
|
||||
};
|
||||
media_session
|
||||
}
|
||||
}
|
||||
|
||||
pub fn new(window: &Window) -> DomRoot<MediaSession> {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue