fix for in array
update hist