Don't crash when run from TextTransform.exe

The cast of Host inside __getTemplateProject failed