tag function bugfix
Merge pull request #295 from leoliang/master

tag function bugfix