you forgot to rename ``$attributes`` to ``$tags`` here