File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed
services/static-webserver/client/source/class/osparc/info Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -227,12 +227,15 @@ qx.Class.define("osparc.info.CommentAdd", {
227227 osparc . study . Conversations . notifyUser ( this . __studyData [ "uuid" ] , this . __conversationId , userGroupId )
228228 . then ( data => {
229229 this . fireDataEvent ( "commentAdded" , data ) ;
230- // OM: push redis notification
231- osparc . store . Users . getInstance ( ) . getUser ( userGroupId )
232- . then ( user => {
233- const msg = user ? user . getLabel ( ) + this . tr ( " was notified" ) : this . tr ( "Notification sent" ) ;
234- osparc . FlashMessenger . logAs ( msg , "INFO" ) ;
235- } ) ;
230+ const potentialCollaborators = osparc . store . Groups . getInstance ( ) . getPotentialCollaborators ( ) ;
231+ if ( userGid in potentialCollaborators ) {
232+ if ( "getUserId" in potentialCollaborators [ userGid ] ) {
233+ const uid = potentialCollaborators [ userGid ] . getUserId ( ) ;
234+ osparc . notification . Notifications . pushConversationNotification ( uid , studyData [ "uuid" ] ) ;
235+ }
236+ const msg = "getLabel" in potentialCollaborators [ userGid ] ? potentialCollaborators [ userGid ] . getLabel ( ) + this . tr ( " was notified" ) : this . tr ( "Notification sent" ) ;
237+ osparc . FlashMessenger . logAs ( msg , "INFO" ) ;
238+ }
236239 } ) ;
237240 }
238241 } ,
You can’t perform that action at this time.
0 commit comments