Skip to content

Commit 952ddfd

Browse files
committed
ts: lib/auth/oauth2/index.js
1 parent da67383 commit 952ddfd

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

lib/auth/oauth2/index.js renamed to lib/auth/oauth2/index.ts

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
1-
'use strict'
1+
import {Router} from 'express'
2+
import * as passport from 'passport'
23

3-
const Router = require('express').Router
4-
const passport = require('passport')
4+
import * as config from '../../config'
5+
import {passportGeneralCallback, setReturnToFromReferer} from '../utils'
6+
import {OAuth2CustomStrategy} from './strategy'
57

6-
const config = require('../../config')
7-
const { setReturnToFromReferer, passportGeneralCallback } = require('../utils')
8-
const { OAuth2CustomStrategy } = require('./strategy')
9-
10-
const oauth2Auth = module.exports = Router()
8+
const oauth2Auth = Router()
9+
export = oauth2Auth
1110

1211
passport.use(new OAuth2CustomStrategy({
1312
authorizationURL: config.oauth2.authorizationURL,

0 commit comments

Comments
 (0)