From 16fb0959672e344c6889483d609e33caaac4b498 Mon Sep 17 00:00:00 2001 From: tom <108757230+tom-quiltt@users.noreply.github.com> Date: Mon, 5 Feb 2024 17:49:13 -0800 Subject: [PATCH] A hack to force Plaid link to user redirect flow so SDK can intercept url (#8) --- Sources/QuilttConnector/QuilttConnectorWebview.swift | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Sources/QuilttConnector/QuilttConnectorWebview.swift b/Sources/QuilttConnector/QuilttConnectorWebview.swift index 98c95a9..e633178 100644 --- a/Sources/QuilttConnector/QuilttConnectorWebview.swift +++ b/Sources/QuilttConnector/QuilttConnectorWebview.swift @@ -28,6 +28,8 @@ class QuilttConnectorWebview: WKWebView, WKNavigationDelegate { // self.isInspectable = true // } self.navigationDelegate = self // to manage navigation behavior for the webview. + // A hack to force Plaid to redirect flow over popup + self.customUserAgent = "Mozilla/5.0 (Linux; Android 14; sdk_gphone64_arm64 Build/UPB5.230623.003; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/113.0.5672.136 Mobile Safari/537.36" } required init?(coder: NSCoder) {