Issue #2249723 by andrei.dincu: Remove entity state variables in hook_uninstall()