Color coding breaks ls?

I found a script that almost takes care of a bit of clunkiness in git. I say almost, because when I use it, after it does what it's supposed to do, it breaks my shell, or something. After I use it, I can't use wildcards any more. I tried to run `jshint *.js` as I do a million times a day, but it says it can't find any such files. `ls` does the same thing. I can do `ls` by itself, and everything is there, but `ls *.js` or `ls *` just says the files aren't there. I tried googling, but to tell the truth, I don't have a clear idea of what to google for. "bash script breaks ls" didn't turn up anything useful. Can anyone tell me what is wrong with it?

green=`tput setaf 2`
reset=`tput sgr0`

git-branch-list() {
  set -f
  git branch | while read line; do
    current="  "
    name=${line##\* }   ## removes leading * for current

    if [ ! "$name" = "$line" ]; then
      current="${green}* "
    fi

    description=`git config branch.$name.description`

    if [ "$description" != "" ]; then
      description=" : $description"
    fi

    echo "${reset}${current}${name}${description}${reset}"
  done
}

The offender seems to be set -f . This option tells the shell to disable expansion of wildcards. Putting set +f at the end of the function should solve the problem.

    ...
    done
    set +f
}

set -f turns off the wildcard globbing, and the effect is global. (Putting it in a function is a bit misleading.)
I see hardly a need for it in the function because most $variables are in quotes that also disables globbing.
So delete it or disable it with

# set -f

and harden this line

  description=`git config "branch.$name.description"`

Thank you guys so much! When I first saw the problem, I didn't associate it with the script. I thought my file system was corrupted. I almost reinstalled the os on my machine. Thanks again.

P.S. It works great, but of course you knew it would.