1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-01 03:40:16 +02:00

Style fix, constants

This commit is contained in:
Hugo Lindström
2012-11-28 20:29:05 +01:00
parent 42dbdd82c9
commit 81eb256326

View File

@@ -406,9 +406,11 @@ ChartsPlugin::chartsList()
if ( !ok )
{
tDebug( LOGVERBOSE ) << Q_FUNC_INFO << "Failed to parse expire headers!";
tDebug( LOGVERBOSE ) << Q_FUNC_INFO << reply->url();
tDebug( LOGVERBOSE ) << Q_FUNC_INFO << reply->rawHeaderPairs();
}
// We'll populate charts with the data from the server
QVariantMap charts;
QString chartName;
@@ -433,7 +435,7 @@ ChartsPlugin::chartsList()
const QString geo = chart.value( "geo" ).toString();
QString name = chart.value( "genre" ).toString();
const QString type = QString( chart.value( "type" ).toString() + "s" );
bool isDefault = ( chart.contains( "default" ) && chart[ "default" ].toInt() == 1 );
const bool isDefault = ( chart.contains( "default" ) && chart[ "default" ].toInt() == 1 );
// Hack!
// Japan charts contains multiple duplicates, all which are linked
@@ -477,9 +479,7 @@ ChartsPlugin::chartsList()
c[ "label" ] = name;
c[ "type" ] = "album";
if ( isDefault )
{
c[ "default" ] = "true";
}
/// If this item has expired, set it to 0.
c[ "expires" ] = ( ok ? QString::number (expires ) : QString::number( 0 ) );