Hey — I think the AI explanation you were given is missing a key part of how this plugin actually works.
Yes, SetEnabled(false) only flips the in-memory flag — that part is correct. But the conclusion that stack sizes aren’t reverted is wrong. In this plugin, RevertStackSize() is called from Save(), and Save() is triggered whenever the UI is closed.
So the real flow is:
Disable in UI
Close UI
Save() runs
RevertStackSize() executes
Stack sizes go back to vanilla
Because of that, the stack values are not left modified after disabling — they’re reverted as part of the normal lifecycle. The scenario described (values staying overridden indefinitely) doesn’t line up with how the code actually executes.
If you’re seeing stacks not reverting, it’s almost certainly something else — leftover data in /oxide/data, another plugin touching item definitions, or the UI not completing its save cycle — not RevertStackSize() being skipped.
I’d recommend testing from a clean state before assuming the core logic is broken. If you can reproduce it step-by-step on a fresh setup, I’m happy to take a look — but right now this looks like a misdiagnosis, not a bug.