updated tag validation