make config XTemplate optional. Fixes #4