// NewOauthManager return new oauth manager.
NewOauthManager return new oauth manager.
// NewOauthManager return new oauth manager .
func NewOauthManager(db database.MgoSession, r service.InternalRegistry, s *config.Session, h *config.Hydra, apiCfg *config.Server) OauthManagerInterface {
	m := &OauthManager{
		ApiCfg:                  apiCfg,
		hydraConfig:             h,
		r:                       r,
		userService:             service.NewUserService(db),
		userIdentityService:     service.NewUserIdentityService(db),
		authLogService:          service.NewAuthLogService(db),
		identityProviderService: service.NewAppIdentityProviderService(),
		session:                 service.NewSessionService(s.Name),
	}
	return m
}
func NewOauthManager ( db database . MgoSession , r service . InternalRegistry , s * config . Session , h * config . Hydra , apiCfg * config . Server ) OauthManagerInterface { m := & OauthManager { ApiCfg : apiCfg , hydraConfig : h , r : r , userService : service . NewUserService ( db ) , userIdentityService : service . NewUserIdentityService ( db ) , authLogService : service . NewAuthLogService ( db ) , identityProviderService : service . NewAppIdentityProviderService ( ) , session : service . NewSessionService ( s . Name ) , } return m }
NewOauthManager return new oauth manager.
NewOauthManager return new oauth manager .