Cache update should be done after database writing and not before, if we want to take profit of the cache.
Use cache to find out if we should write a new "flagged"/starred status into database.

Should speed up Google Reader refreshes.
Merge pull request #127 from barijaona/database

Database