First check whether it is the default config before touching

Potentially fixes https://github.com/owncloud/core/issues/11678

@PVince81