Maybe if items assigned once you entered town menu (before even choosing to upgrade item or get a new item), it could prevent abusing the system and allow player to return if they missclicked.