From 2e0cab59ff77ee1c36a68cca1dfec02c553b767f Mon Sep 17 00:00:00 2001 From: "Uwe L. Korn" Date: Mon, 30 Jun 2014 16:40:24 +0100 Subject: [PATCH] Better support for play.spotify.com --- src/libtomahawk/utils/SpotifyParser.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libtomahawk/utils/SpotifyParser.cpp b/src/libtomahawk/utils/SpotifyParser.cpp index 194541c2c..71fa4efbe 100644 --- a/src/libtomahawk/utils/SpotifyParser.cpp +++ b/src/libtomahawk/utils/SpotifyParser.cpp @@ -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 ); }