1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-06 22:26:32 +02:00

Better support for play.spotify.com

This commit is contained in:
Uwe L. Korn
2014-06-30 16:40:24 +01:00
parent 5508212635
commit 2e0cab59ff

View File

@@ -196,10 +196,10 @@ SpotifyParser::lookupTrack( const QString& link )
// we need Spotify URIs such as spotify:track:XXXXXX, so if we by chance get a http://open.spotify.com url, convert it
QString uri = link;
if ( link.contains( "open.spotify.com" ) )
if ( link.contains( "open.spotify.com" ) || link.contains( "play.spotify.com" ) )
{
QString hash = link;
hash.replace( "http://open.spotify.com/track/", "" );
hash.replace( "http://open.spotify.com/track/", "" ).replace( "http://play.spotify.com/track/", "" );
uri = QString( "spotify:track:%1" ).arg( hash );
}