fix to work with latest mwtemplates