I’ve double-checked the code and it was a problem with the attribute definition.
In general I’ve seen very few explanations (on the web) about how to work with attributes for more advanced projects. I think it would be an interesting addition for future courses you might create.