Fix for blanks tags and also fixed the sorting of tags.  Fixes issue #1