refactored configuration to save all file configs to an object and retur...

...n.