Fix bug when error event template loads.