bug fixed. Application crashes on add any template type other that text