checked fix bug with template and constant