modify for omniauth 1.0
refactor for oauth 2
Merge pull request #1 from quake/master

code refactoring for omniauth 1.0 and oauth 2.0