style(clippy): enforce clippy use_self lint
Clippy's `use_self` line ensures that `Self` is used instead of the real name whenever possible. This makes searching easier and cleans up the code a bit.
This commit is contained in:
committed by
Henrik Friedrichsen
parent
01e01b59e4
commit
fe8f8e78ee
@@ -49,10 +49,10 @@ pub struct Queue {
|
||||
}
|
||||
|
||||
impl Queue {
|
||||
pub fn new(spotify: Spotify, cfg: Arc<Config>, library: Arc<Library>) -> Queue {
|
||||
pub fn new(spotify: Spotify, cfg: Arc<Config>, library: Arc<Library>) -> Self {
|
||||
let queue_state = cfg.state().queuestate.clone();
|
||||
let playback_state = cfg.state().playback_state.clone();
|
||||
let queue = Queue {
|
||||
let queue = Self {
|
||||
queue: Arc::new(RwLock::new(queue_state.queue)),
|
||||
spotify: spotify.clone(),
|
||||
current_track: RwLock::new(queue_state.current_track),
|
||||
|
||||
Reference in New Issue
Block a user