Fixes #691, allow mainConfigFile to be an array