[Tex/LaTex] How to put the logo on the upper left side

beamer

How to put the logo of my university on the upper left side?,
I do not want to have the logo on the right side

example-image-a i should change to direcction of my logo university?

\documentclass{beamer}
\usetheme{Berkeley}

\def\insertlogoright{\usebeamertemplate*{logoright}}
\def\logoright{\setbeamertemplate{logoright}}

\makeatletter
  \defbeamertemplate*{headline}{mycustom theme}
  {%
    \begin{beamercolorbox}[wd=\paperwidth]{frametitle}
      \ifx\beamer@sidebarside\beamer@lefttext%
      \else%
        \hfill%
      \fi%
      \ifdim\beamer@sidebarwidth>0pt%  
        \usebeamercolor[bg]{logo}%
        \vrule width\beamer@sidebarwidth height \beamer@headheight%
        \hskip-\beamer@sidebarwidth%
        \hbox to \beamer@sidebarwidth{%
        \hss%
        \vbox to \beamer@headheight{%
        \vss\hbox{\color{fg}\insertlogo}\vss%
        }%
        \hss}%
        \hfill%
        \hbox to \beamer@sidebarwidth{%
        \hss%
        \vbox to \beamer@headheight{%
        \vss\hbox{\color{fg}\insertlogoright}\vss%
        }%
        \hss}%
      \else%
        \vrule width0pt height \beamer@headheight%  
      \fi%
    \end{beamercolorbox}
  }
\makeatother

\logo{\includegraphics[width=1.2cm,keepaspectratio]{example-image-a}}
\logoright{\includegraphics[width=1.2cm,keepaspectratio]{example-image-b}}


\title{The Title}
\author{The Author}
\institute{The Institute}

\begin{document}

{
 \setbeamertemplate{logo}{}
 \setbeamertemplate{logoright}{}
 \begin{frame}
  \maketitle
 \end{frame}
}

\begin{frame}{this}
 test
\end{frame}

\end{document}

i want this result:
enter image description here

Best Answer

If you use the default headline instead of your customisation, the logo will be at the top left by default.

\documentclass{beamer}
\usetheme{Berkeley}

\logo{\includegraphics[width=1.2cm,keepaspectratio]{example-image-a}}

\title{The Title}
\author{The Author}
\institute{The Institute}

\begin{document}

\begin{frame}
  \maketitle
\end{frame}

\begin{frame}{this}
 test
\end{frame}

\end{document}

enter image description here