It is not (in my testing) required for deb upgrade (I have not tried rpm).

It makes no sense to call the initialization functions for a newly installed package in the "post uninstall" hook - and doing so in the deb file case actually causes the initialization to be executed twice when upgrading.

Please provide more information about the issue that this hack was supposed to fix, and how this hack fixes it.