updated configuration file as well using function handles rather than calling functions