refactor with hyper