fix badge bug when offline
Merge pull request #33 from PerryPan/master

fix badge bug when request failed