General code cleanup
Fixed various tagging issues