fix hash change code, remove global functions

[#68511996]