changed traverse a little bit