Parcourir la source

:pencil2: Clean up comments, change sessionToken to sessionData

tags/0.0.3^2
tomit4 il y a 3 ans
Parent
révision
312d19cabc

+ 0
- 2
backend/lib/services/user.js Voir le fichier

@@ -111,13 +111,11 @@ module.exports = class UserService extends Schmervice.Service {
111 111
      * @returns
112 112
      */
113 113
     async findByUserEmail(userEmail, txn) {
114
-        console.log('userEmail :=>', userEmail)
115 114
         const { User } = this.server.models()
116 115
         const user = await User.query(txn)
117 116
             .throwIfNotFound()
118 117
             .first()
119 118
             .where({ user_email: userEmail })
120
-        console.log('user :=>', user)
121 119
         return user
122 120
     }
123 121
 

+ 0
- 2
frontend/src/services/user.service.js Voir le fichier

@@ -1,4 +1,3 @@
1
-import { when } from 'joi'
2 1
 import { db } from '../utils/db.js'
3 2
 
4 3
 /**
@@ -16,7 +15,6 @@ const signupUser = async user => {
16 15
 }
17 16
 
18 17
 const fetchUserByEmail = async userEmail => {
19
-    console.log('userEmail :=>', userEmail)
20 18
     return await db.get(`/user/fetchbymail/${userEmail}`)
21 19
 }
22 20
 

+ 2
- 8
frontend/src/views/OnboardingView.vue Voir le fichier

@@ -30,7 +30,7 @@ main.view--onboarding
30 30
             p(v-if='currentStep != 0') You have completed: {{ currentStep }} / {{ survey.steps.length }} survey steps
31 31
 
32 32
     article(v-else)
33
-        SurveyCompleteView(:answers='answered' :surveySteps='survey.steps' :currentProfileId='currentProfileId')
33
+        SurveyCompleteView(:answers='answered' :surveySteps='survey.steps')
34 34
 </template>
35 35
 
36 36
 <script>
@@ -41,7 +41,6 @@ import {
41 41
     fetchProfileByProfileId,
42 42
 } from '../services/profile.service.js'
43 43
 import { surveyFactory } from '@/utils'
44
-import { currentProfile } from '../services/'
45 44
 import stepViews from '@/components/onboarding'
46 45
 import SurveyCompleteView from './SurveyCompleteView.vue'
47 46
 
@@ -62,11 +61,6 @@ export default {
62 61
         invalidResponse: false,
63 62
         authenticator: {},
64 63
     }),
65
-    computed: {
66
-        cP() {
67
-            return currentProfile ? currentProfile : null
68
-        },
69
-    },
70 64
     async created() {
71 65
         this.survey = await surveyFactory.createSurvey()
72 66
         this.authenticator = new Authenticator()
@@ -77,7 +71,7 @@ export default {
77 71
                     sessionToken,
78 72
                 )
79 73
                 // NOTE: Left off here, INCOMPLETE, no ACCESS TOKEN yet, crazy amount of logic here...
80
-                if (sessionToken.isValid) {
74
+                if (sessionData.isValid) {
81 75
                     const userEmail = sessionData.payload.email
82 76
                     const emailIsInCache =
83 77
                         await this.authenticator.checkEmailCache(userEmail)

Chargement…
Annuler
Enregistrer