decrease memory usage of TemplateResolver
add site category awared template resolver