(integrationId: string | null)
| 95 | ); |
| 96 | |
| 97 | function getIntegration(integrationId: string | null) { |
| 98 | if (integrationId === APP_NOTIFICATION_INTEGRATION_ID) { |
| 99 | return { |
| 100 | integrationId: null, |
| 101 | sendToApp: true, |
| 102 | sendToEmail: false, |
| 103 | }; |
| 104 | } |
| 105 | |
| 106 | if (integrationId === EMAIL_NOTIFICATION_INTEGRATION_ID) { |
| 107 | return { |
| 108 | integrationId: null, |
| 109 | sendToApp: false, |
| 110 | sendToEmail: true, |
| 111 | }; |
| 112 | } |
| 113 | |
| 114 | return { |
| 115 | sendToApp: false, |
| 116 | sendToEmail: false, |
| 117 | integrationId, |
| 118 | }; |
| 119 | } |
| 120 | |
| 121 | function stripNullChars<T>(value: T): T { |
| 122 | if (typeof value === 'string') { |
no outgoing calls
no test coverage detected