extragear/multimedia/amarok/src rev 570617

Jeff Mitchell kde-dev at emailgoeshere.com
Mon Aug 7 15:08:56 UTC 2006


Quoting Andrew Turner <andrewturner512 at googlemail.com>:

> Jeff,
>
> Read my comment:
> //No tables seem to exist (as doing a count(url) didn't even return
> any number, even 0)
>
> The actual test in isValid is for the return value of the queries
> (which do a count(url)) to be empty. If the tables were empty, the
> return value should be a QStringList of {"0"}, as far as I understand
> SQL. "0" is not an empty string. So, even if all the tables are empty,
> isValid should still be true. The only way for isValid to return false
> is for every table to not exist, hence generating an empty QStringList
> for every query.
>
> So, I think my change is correct. But, feel free to respond if you
> disagree with my reasoning.

Nope, sounds good.  I have convinced myself that doing the drops would  
be a safe operation and would not reintroduce the old stats bug  
(because if any url exists in statistics the count would be higher  
than 0, so you could only drop if there was already nothing  
there...and the isInitialized() check is not there anymore) but  
assuming you are correct in what you think should be returned it  
sounds great.

--Jeff




More information about the Amarok mailing list