working update and refactored tag data extraction