Catch preupgrade exception
Merge pull request #1916 from owncloud/fix-1863

Catch preupgrade exception