- minor formatting fixes
- handling invalid tag