fix recursive mash