Fixed bug with templates which contain nothing but a single region.