Few cleanups to config loading