浏览代码

:recycle: commenting out auth def in profile.js

undefined
j 2 年前
父节点
当前提交
73f5b0b339
共有 1 个文件被更改,包括 5 次插入7 次删除
  1. 5
    7
      backend/lib/plugins/profile.js

+ 5
- 7
backend/lib/plugins/profile.js 查看文件

@@ -1,9 +1,6 @@
1 1
 const Objection = require('objection')
2 2
 const Schmervice = require('@hapipal/schmervice')
3 3
 
4
-const Jwt = require('hapi-auth-jwt2')
5
-const JwtStrategy = require('../auth/strategies/jwt')
6
-
7 4
 const ProfileModel = require('../models/profile')
8 5
 const TagModel = require('../models/tag')
9 6
 const TagAssociationModel = require('../models/tag-association')
@@ -41,10 +38,11 @@ module.exports = {
41 38
         await server.registerModel(ZipCodeModel)
42 39
         await server.registerModel(MatchQueueModel)
43 40
 
44
-        const mainApp = server.registrations['main-app-plugin']
45
-        const jwtOptions = JwtStrategy(mainApp.options)
46
-        server.auth.strategy('default_jwt', 'jwt', jwtOptions)
47
-        server.auth.default('default_jwt')
41
+        // TODO: Need for testing but can't uncomment
42
+        // const mainApp = server.registrations['main-app-plugin']
43
+        // const jwtOptions = JwtStrategy(mainApp.options)
44
+        // server.auth.strategy('default_jwt', 'jwt', jwtOptions)
45
+        // server.auth.default('default_jwt')
48 46
 
49 47
         // Bind to global context
50 48
         // So we can use Objection transactions

正在加载...
取消
保存