Oh-My-Zsh: Fix for parse error near elif

I am using Oh My Zsh in my multi terminal setup in Windows. I recently updated the Oh My Zsh and it immediately started throwing error 'parse error near elif'. I had enabled the git plugin for Oh My Zsh and it was not working because of this error.

It turns out that the (temporary) fix is very simple to solve this error:

Inside your Oh My Zsh terminal, run the following commands:

cd $ZSH
git config core.autocrlf false
git rm --cached -r .
git reset --hard

And restart your terminal. After that you should not see that error message again and everything should be back to normal.

undefined