Refactor gumhelper