fix bug
before refact
profile include subtemplate
almost done