mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-03-20 15:59:42 +01:00
* Don't double-check playback-logs for remotes.
This commit is contained in:
parent
334951e34c
commit
d0207152b6
@ -78,7 +78,7 @@ DatabaseCommand_LogPlayback::exec( DatabaseImpl* dbi )
|
||||
QVariant srcid = source()->isLocal() ? QVariant( QVariant::Int ) : source()->id();
|
||||
TomahawkSqlQuery query = dbi->newquery();
|
||||
|
||||
if ( m_playtime > 0 )
|
||||
if ( m_playtime > 0 && source()->isLocal() )
|
||||
{
|
||||
query.prepare( QString( "SELECT * FROM playback_log WHERE source %1 AND playtime = %2" ).arg( srcid.isNull() ? "IS NULL" : srcid.toString() ).arg( m_playtime ) );
|
||||
query.exec();
|
||||
@ -88,7 +88,8 @@ DatabaseCommand_LogPlayback::exec( DatabaseImpl* dbi )
|
||||
return;
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
if ( m_playtime == 0 )
|
||||
m_playtime = QDateTime::currentDateTimeUtc().toTime_t();
|
||||
|
||||
// tDebug() << "Logging playback of" << m_artist << "-" << m_track << "for source" << srcid << "- timestamp:" << m_playtime;
|
||||
|
Loading…
x
Reference in New Issue
Block a user