modification of template to complete #20