Q: Why are my enchants being wiped when a goal is reached?
A: You have an invalid enchantment in milestones.yml. The default configuration is built for 1.19.3, so you need to use enchants that are valid for your server version.
For example, efficiency would be:
1.8 DIG_SPEED:1
1.16 efficiency:1
Use the Bukkit names for 1.8-1.12
Use the actual names for 1.13+