Added template directory to config file parsing.
Fixed a small problem with converting strings to strings or paths.