fixed ienumerable and threading