Making swagger.js compatible with Draft 2 of Swagger OAuth2