It happens if the git is not updated to the latest version.
Please update the git and you are good to go.
To update the git, just follow the below command depending on the type of OS you are using:
windows: git update-git-for-windows
Linux/Unix: git update
or follow the below link to get the latest copy of the git client for your OS
https://git-scm.com/downloads