Skip to content

Commit

Permalink
assign applicationNameForUserAgent to WKWebViewConfiguration
Browse files Browse the repository at this point in the history
  • Loading branch information
crazyleaf9999 committed Jul 7, 2020
1 parent c1ab57e commit 3b65ae8
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions ios/Classes/InAppWebView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1077,6 +1077,12 @@ public class InAppWebView: WKWebView, UIScrollViewDelegate, WKUIDelegate, WKNavi
}
}
}

if #available(iOS 9.0, *) {
if let applicationNameForUserAgent = options?.applicationNameForUserAgent, !applicationNameForUserAgent.isEmpty {
configuration.applicationNameForUserAgent = applicationNameForUserAgent
}
}

return configuration
}
Expand Down

0 comments on commit 3b65ae8

Please # to comment.