Fixed database patching script permissions: using queryF instead of query to override $allowWebChanges checking