I guess our users are more interested in classic Facebook page than JSON.

Not sure why Echonest returns graph URL.
This commit is contained in:
Arnaud Bienner 2014-12-27 00:47:24 +01:00
parent 9cb2a17f37
commit c5b6f7b531
1 changed files with 5 additions and 1 deletions

View File

@ -93,7 +93,11 @@ void EchoNestBiographies::RequestFinished() {
QString text;
// Add a link to the bio webpage at the top if we have one
if (!bio.url().isEmpty()) {
text += "<p><a href=\"" + bio.url().toEncoded() + "\">" +
QString bio_url = bio.url().toEncoded();
if (bio.site() == "facebook") {
bio_url.replace("graph.facebook.com", "www.facebook.com");
}
text += "<p><a href=\"" + bio_url + "\">" +
tr("Open in your browser") + "</a></p>";
}