Handle empty $tagId array