fixed issue with the same depth entities