clippy: Fix some warnings in components/script (#31735)

* fix clippy problems

* fix clippy error

* fix clippy error

* fix clippy error

* fix clippy error

* fix clippy error

* fix clippy errors
This commit is contained in:
Rosemary Ajayi 2024-03-19 08:01:23 +00:00 committed by GitHub
parent 291fbce434
commit 06a021db55
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 60 additions and 69 deletions

View file

@ -299,13 +299,13 @@ impl ImageCacheListener for HTMLVideoElement {
ImageResponse::Loaded(image, url) => {
debug!("Loaded poster image for video element: {:?}", url);
self.htmlmediaelement.process_poster_image_loaded(image);
LoadBlocker::terminate(&mut *self.load_blocker.borrow_mut());
LoadBlocker::terminate(&mut self.load_blocker.borrow_mut());
},
ImageResponse::MetadataLoaded(..) => {},
// The image cache may have loaded a placeholder for an invalid poster url
ImageResponse::PlaceholderLoaded(..) | ImageResponse::None => {
// A failed load should unblock the document load.
LoadBlocker::terminate(&mut *self.load_blocker.borrow_mut());
LoadBlocker::terminate(&mut self.load_blocker.borrow_mut());
},
}
}