Quellcode durchsuchen

:recycle: cleaned and commented code in prep for testing before code review

tags/0.0.1^2
K Rob vor 3 Jahren
Ursprung
Commit
3265703007
2 geänderte Dateien mit 7 neuen und 8 gelöschten Zeilen
  1. 6
    3
      frontend/src/services/chat.service.js
  2. 1
    5
      frontend/src/services/login.service.js

+ 6
- 3
frontend/src/services/chat.service.js Datei anzeigen

102
             
102
             
103
         //  step 1: build the this.groupings object from the backend
103
         //  step 1: build the this.groupings object from the backend
104
         this.getGroupingsByProfileId(this.uuid)
104
         this.getGroupingsByProfileId(this.uuid)
105
-        //  step 2: build the this.subscriptions array from the this.groupings object
106
-        console.log('this.subscriptions: ', this.subscriptions)
105
+        
107
         //  step 3: subscribe to the this.subscriptions array
106
         //  step 3: subscribe to the this.subscriptions array
107
+        console.log('this.subscriptions: ', this.subscriptions)
108
+        
108
         this._listenFor({ listeners: this.listeners })
109
         this._listenFor({ listeners: this.listeners })
109
         this._subscribe(this.subscriptions)
110
         this._subscribe(this.subscriptions)
110
     }
111
     }
134
     _listenFor({ listeners }) {
135
     _listenFor({ listeners }) {
135
         providerMethods['listen'](listeners)
136
         providerMethods['listen'](listeners)
136
     }
137
     }
137
-
138
+    
139
+    //  step 2: build the this.subscriptions array from the this.groupings object
138
     // fetch all groupings for this profile and then store them in the chatter groupings object for reference
140
     // fetch all groupings for this profile and then store them in the chatter groupings object for reference
139
     async getGroupingsByProfileId(profileId) {
141
     async getGroupingsByProfileId(profileId) {
140
         console.log('fetching groupings for profileId:', profileId)
142
         console.log('fetching groupings for profileId:', profileId)
141
         const groupings = await fetchMembershipsByProfileId(profileId)
143
         const groupings = await fetchMembershipsByProfileId(profileId)
142
         this.groupings = groupings
144
         this.groupings = groupings
145
+       
143
         this.createChannelNamesByGroupings(this.groupings)
146
         this.createChannelNamesByGroupings(this.groupings)
144
     }
147
     }
145
     // building a list of channel names from the groupings object.grouping_name
148
     // building a list of channel names from the groupings object.grouping_name

+ 1
- 5
frontend/src/services/login.service.js Datei anzeigen

105
         this.chatter = new Chatter()
105
         this.chatter = new Chatter()
106
         // Use the reactive id object
106
         // Use the reactive id object
107
         const testAccountUUID = this.id.value
107
         const testAccountUUID = this.id.value
108
-        this.chatter.setup(testAccountUUID).then(() => {
109
-            console.log('chatter setup complete')
110
-           
111
-        })
112
-        
108
+        this.chatter.setup(testAccountUUID)
113
     }
109
     }
114
 
110
 
115
     
111
     

Laden…
Abbrechen
Speichern