Implemented correct Config parsing with Factory.