Added check for database

If there is database that is inside user documents directory we assume
that this is newer than the one from inside application bundle