Fixed major bug for threading
0.6.5.1