Affirm / affirm-merchant-sdk-ios

Integrate Affirm into your iOS app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

AffirmPrequalModalViewController does not open affirm.com/lenders link

jan-bednar opened this issue · comments

To reproduce:
Open AffirmPrequalModalViewController
Scroll down
Tap affirm.com/lenders link in the description text

Expected result:
Link is opened in new modal web view or handled by system to be opened outside of app

Actual result:
Tapping link does not do anything

Simulator Screen Shot - iPhone 13 - 2022-05-13 at 10 12 59

Code:

AffirmPrequalModalViewController
(void)webView:(WKWebView *)webView decidePolicyForNavigationAction:(WKNavigationAction *)navigationAction decisionHandler:(void (^)(WKNavigationActionPolicy))decisionHandler

is called with navigation action:

<WKNavigationAction: 0x14b70b1a0; navigationType = 0; syntheticClickType = 1; position x = 325.00 y = 1037.00 request = <NSMutableURLRequest: 0x6000010e0520> { URL: https://www.affirm.com/lenders }; sourceFrame = <WKFrameInfo: 0x14b70b020; webView = 0x14a349000; isMainFrame = YES; request = <NSMutableURLRequest: 0x6000010ed160> { URL: https://sandbox.affirm.com/apps/prequal/?use_promo=true&page_type=product&public_api_key=XKKXP93HXGUP0TFK&unit_price=84900&referring_url=https://iossdk/ }>; targetFrame = (null)>

decision handler is called with WKNavigationActionPolicyAllow but navigation does not happen