Skip to content

Commit

Permalink
chore(debug): add extra loggin around mobile messaging
Browse files Browse the repository at this point in the history
  • Loading branch information
schnogz committed Nov 11, 2021
1 parent fcb2ba0 commit 376a859
Showing 1 changed file with 12 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { hasPath, pathOr } from 'ramda'
import { END, eventChannel } from 'redux-saga'
import { call, put, select, take } from 'redux-saga/effects'
import { hasPath } from 'ramda'

import { actions, selectors } from 'data'
import {
AccountUnificationFlows,
Expand Down Expand Up @@ -52,9 +53,18 @@ const sendMessageToMobile = (
console.log('sendMessageToMobile BCAndroidSSI defined:', hasPath(['BCAndroidSSI'], window))
switch (true) {
// ios
case platform === PlatformTypes.IOS && window.webkit:
case platform === PlatformTypes.IOS:
console.log('sendMessageToMobile ios detected')
try {
console.log(
'sendMessageToMobile webkit.messageHandlers exists?: ',
hasPath(['webkit', 'messageHandlers'], window)
)
try {
console.log(window.webkit.messageHandlers)
} catch (e) {
console.log('messageHandlers missing')
}
console.log(
'sendMessageToMobile connectionStatusHandler exists?: ',
hasPath(['webkit', 'messageHandlers', 'connectionStatusHandler'], window)
Expand Down

0 comments on commit 376a859

Please sign in to comment.