Make FileCache upgrade more robust, fixes #2650
Merge pull request #2741 from owncloud/fix_2650

Make FileCache upgrade more robust, fixes #2650