Im curious, why cscart in case if we changed something in the core files when updating everything is gone, why not just save the changes and only updated the parts that needs to be updated. I want to understand the goal behind this???
The reason I asked this question is, why hooks??
Why not using hooks?? Is there is another way it can be solved ???
Because updating system does not know what has changed. If system would scan every file in CS-Cart and compare it if it matches the old version, updates would take ages.
And even if this was possible, tons of issues still remain. Imagine there is a function. You change how it works, and then CS-Cart update also changes how it works (and the rest of the system expects the function to work in a new way). Which version should be kept?
Hooks exist specifically, so that amateur & professional CS-Cart developers can modify the system without having to alter core files.