Introduced Config and fixed few minor bugs