second commit

Still working on the multithreading issue