### Apache Airflow version

2.1.3 (latest released)

### Operating System

Debian Buster

### Versions of Apache Airflow Providers

_No response_

### Deployment

Managed Services (Astronomer, Composer, MWAA etc.)

### Deployment details

Running `quay.io/astronomer/ap-airflow:2.1.3-buster` Docker image

### What happened

In the task attributes view of a BashOperator, the `template_ext` row doesn't show any value, while I would expect to see `('.sh', '.bash')`.

![image](https://user-images.githubusercontent.com/6249654/131467817-8620f68d-0f3d-491d-ad38-cbf5b91cdcb3.png)


### What you expected to happen

Expect to see correct `template_ext` value

### How to reproduce

Run a BashOperator and browse to Instance Details --> scroll down to `template_ext` row

### Anything else

Spent a little time trying to figure out what could be the reason, but haven't found the problem yet. Therefore created issue to track.

### Are you willing to submit PR?

- [X] Yes I am willing to submit a PR!

### Code of Conduct

- [X] I agree to follow this project's [Code of Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)

airflow/models/baseoperator.py
new_cls = super().__new__(cls, name, bases, namespace, **kwargs)
        new_cls.__init__ = cls._apply_defaults(new_cls.__init__)
        return new_cls
@functools.total_ordering
class BaseOperator(Operator, LoggingMixin, TaskMixin, metaclass=BaseOperatorMeta):
    """
    Abstract base class for all operators. Since operators create objects that
    become nodes in the dag, BaseOperator contains many recursive methods for
    dag crawling behavior. To derive this class, you are expected to override
    the constructor as well as the 'execute' method.
    Operators derived from this class should perform or trigger certain tasks
    synchronously (wait for completion). Example of operators could be an
    operator that runs a Pig job (PigOperator), a sensor operator that
    waits for a partition to land in Hive (HiveSensorOperator), or one that
    moves data from Hive to MySQL (Hive2MySqlOperator). Instances of these
    operators (tasks) target specific operations, running specific scripts,
    functions or data transfers.
    This class is abstract and shouldn't be instantiated. Instantiating a
    class derived from this one results in the creation of a task object,
    which ultimately becomes a node in DAG objects. Task dependencies should
    be set by using the set_upstream and/or set_downstream methods.
    :param task_id: a unique, meaningful id for the task
    :type task_id: str
    :param owner: the owner of the task. Using a meaningful description
        (e.g. user/person/team/role name) to clarify ownership is recommended.
    :type owner: str