@@ -10,7 +10,6 @@ import {
10
10
useTrackEvent ,
11
11
ANALYTICS_NOTIFICATION_PORT_BLOCK_ERROR ,
12
12
} from '../redux/analytics'
13
- import { useIsFlex } from '../organisms/Devices/hooks/useIsFlex'
14
13
15
14
import type { UseQueryOptions } from 'react-query'
16
15
import type { HostConfig } from '@opentrons/api-client'
@@ -41,7 +40,6 @@ export function useNotifyService<TData, TError = Error>({
41
40
const host = hostOverride ?? hostFromProvider
42
41
const hostname = host ?. hostname ?? null
43
42
const doTrackEvent = useTrackEvent ( )
44
- const isFlex = useIsFlex ( host ?. robotName ?? '' )
45
43
const seenHostname = React . useRef < string | null > ( null )
46
44
const { enabled, staleTime, forceHttpPolling } = options
47
45
@@ -81,8 +79,7 @@ export function useNotifyService<TData, TError = Error>({
81
79
function onDataEvent ( data : NotifyResponseData ) : void {
82
80
if ( data === 'ECONNFAILED' || data === 'ECONNREFUSED' ) {
83
81
setRefetch ( 'always' )
84
- // TODO(jh 2023-02-23): remove the robot type check once OT-2s support MQTT.
85
- if ( data === 'ECONNREFUSED' && isFlex ) {
82
+ if ( data === 'ECONNREFUSED' ) {
86
83
doTrackEvent ( {
87
84
name : ANALYTICS_NOTIFICATION_PORT_BLOCK_ERROR ,
88
85
properties : { } ,
0 commit comments