
    D6i>                     .    d dl Z d dlmZ  G d de      Zy)    N)BaseStoragec                   *    e Zd ZdZddZd Zd Zd Zy)SessionStoragez}
    The default storage backend. Stores and retrieves OAuth tokens using
    the :ref:`Flask session <flask:sessions>`.
    c                     || _         y)a  
        Args:
            key (str): The name to use as a key for storing the OAuth token in the
                Flask session. This string will have ``.format(bp=self.blueprint)``
                called on it before it is used. so you can refer to information
                on the blueprint as part of the key. For example, ``{bp.name}``
                will be replaced with the name of the blueprint.
        N)key)selfr   s     g/home/azureuser/techstart-app/venv/lib/python3.12/site-packages/flask_dance/consumer/storage/session.py__init__zSessionStorage.__init__   s         c                 x    | j                   j                  |      }t        j                  j	                  |      S N)bp)r   formatflasksessiongetr   	blueprintr   s      r	   r   zSessionStorage.get   s+    hhooo+}}  %%r   c                 b    | j                   j                  |      }|t        j                  |<   y r   r   r   r   r   )r   r   tokenr   s       r	   setzSessionStorage.set   s$    hhooo+"cr   c                 ^    | j                   j                  |      }t        j                  |= y r   r   r   s      r	   deletezSessionStorage.delete   s"    hhooo+MM#r   N)z{bp.name}_oauth_token)__name__
__module____qualname____doc__r
   r   r   r    r   r	   r   r      s    
	&#r   r   )r   flask_dance.consumer.storager   r   r   r   r	   <module>r!      s     4[ r   