removed forks, added threads instad, not working yet