Skip to content
This repository has been archived by the owner on Mar 12, 2020. It is now read-only.

Commit

Permalink
Transform real time notifs to typed versions
Browse files Browse the repository at this point in the history
  • Loading branch information
asutula committed Oct 19, 2018
1 parent cb8d6c1 commit 73a8c2e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion App/Services/EventHandlers/TextileNodeEventHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import TextileNodeActions from '../../Redux/TextileNodeRedux'
import NotificationActions from '../../Redux/NotificationsRedux'
import PhotoViewingActions from '../../Redux/PhotoViewingRedux'
import StorageActions from '../../Redux/StorageRedux'
import { toTypedNotification } from '../Notifications'

export default class TextileNodeEventHandler {
store: Store<RootState>
Expand Down Expand Up @@ -40,7 +41,7 @@ export default class TextileNodeEventHandler {
this.store.dispatch(PhotoViewingActions.threadRemoved(payload.id))
})
TextileNode.eventEmitter.addListener('onNotification', (payload) => {
this.store.dispatch(NotificationActions.newNotificationRequest(payload))
this.store.dispatch(NotificationActions.newNotificationRequest(toTypedNotification(payload)))
})
}

Expand Down

0 comments on commit 73a8c2e

Please sign in to comment.