fix smarty error