Can't find element 'minecraft:generic.max_health'

I'm trying to update a datapack from 1.20.4 to 1.21.1 and im running into this issue. Can someone help? This is the command that throws this error: attribute @e[type=minecraft:ender_dragon,limit=1] minecraft:generic.max_health base set 500 this is NOT my datapack, it's a datapack i found which I'm trying to update myself Thanks!
Continue to help post