Fixes #4352 - cannot create and update template
Merge pull request #95 from tstrachota/tpl_fix

Fixes #4352 - cannot create and update template