modify main thread method
Merge pull request #1 from smhjsw/master

modify main thread method