Updated render to help with error logging on template execution.