o
    iF                     @   s   dddZ d S )Nc                 C   s   |du rt | d}|d}W d   n1 sw   Y  |dr+|ddr+dS |dr2d	S |d
r9dS |dr@dS dS )zDetect format of image (Currently supports jpeg, png, webp, gif only)
    Ref: https://github.com/python/cpython/blob/3.11/Lib/imghdr.py
    Ref: https://www.w3.org/Graphics/JPEG/itu-t81.pdf
    Nrb   s   RIFFs   WEBP   webps   PNGpngs   jpegs   GIFgif)openread
startswith)filehf r   H/home/ubuntu/.local/lib/python3.10/site-packages/yt_dlp/compat/imghdr.pywhat   s   


r   )NN)r   r   r   r   r   <module>   s    