MV [Yanfly Item Core: Durability/Upgrade Slots]Remove upgrades on break instead of destroying.

I want to make a system where if an item has been upgraded, durability reaching zero will remove the upgrade rather than destroying it completely. How easy would it be to implement such a system? Can it be done using Lunatic Mode, or will it require modifying the plugin code?

Original thread: https://forums.rpgmakerweb.com/threads/yanfly-item-core-durability-upgrade-slots-remove-upgrades-on-break-instead-of-destroying.143342/