Catch exceptions and show error when save template to repo fails.