Let's not crash servers by using client methods in it...

Also, what you are doing won’t work. You can’t save the info on the
item. Item and ItemStack are different things. There’s only one item
but there are several itemstacks. That’s where you save info.