Fixed error with oauth using sql database

Mongo related classes are not generated when using sql as database.

Fix #701
Merge pull request #714 from atomfrede/missing-dependencies-oauth

Fixed error with oauth using sql database