I would keep this code and check whether there is a template or not in order to render this. Using that approach we can keep untouched the import page and being safer.