Fixing tags check for undefined.
Merge pull request #591 from johnkchiu/develop_2.0

Fixing tags check for undefined.