File tree Expand file tree Collapse file tree 2 files changed +48
-61
lines changed
DesignMode/Widgets/Lyrics Expand file tree Collapse file tree 2 files changed +48
-61
lines changed Original file line number Diff line number Diff line change @@ -58,24 +58,11 @@ - (NSString *)parseLyricsFromData:(NSData *)data response:(NSURLResponse *)respo
5858}
5959
6060- (void )fetchFromLyricsOvh {
61- NSString *artist;
62- NSString *title;
63-
6461 ddb_playItem_t *track = self.track ;
6562 deadbeef->pl_item_ref (track);
6663
67- deadbeef->pl_lock ();
68-
69- const char *str = deadbeef->pl_find_meta (self.track , " artist" );
70- if (str != NULL ) {
71- artist = @(str);
72- }
73- str = deadbeef->pl_find_meta (self.track , " title" );
74- if (str != NULL ) {
75- title = @(str);
76- }
77-
78- deadbeef->pl_unlock ();
64+ NSString *artist = [self currentArtist ];
65+ NSString *title = [self currentTitle ];
7966
8067 if (artist != nil && title != nil ) {
8168 NSURL *url = [[[NSURL URLWithString: @" https://api.lyrics.ovh/v1" ] URLByAppendingPathComponent: artist] URLByAppendingPathComponent: title];
You can’t perform that action at this time.
0 commit comments