Skip to content

Commit

Permalink
fix(mac): fine-grained control [NSAllowsLocalNetworking] is not avail…
Browse files Browse the repository at this point in the history
…able in older operating systems (iOS 10.0 and older, or macOS 10.12 and older)

Close #3377
  • Loading branch information
develar committed Dec 11, 2018
1 parent ddd2b76 commit 930dc8d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/app-builder-lib/src/electron/electronMac.ts
Expand Up @@ -188,6 +188,8 @@ function configureLocalhostAts(appPlist: any) {
}

ats.NSAllowsLocalNetworking = true
// https://github.com/electron-userland/electron-builder/issues/3377#issuecomment-446035814
ats.NSAllowsArbitraryLoads = true

let exceptionDomains = ats.NSExceptionDomains
if (exceptionDomains == null) {
Expand Down
1 change: 1 addition & 0 deletions test/src/helpers/packTester.ts
Expand Up @@ -318,6 +318,7 @@ async function checkMacResult(packager: Packager, packagerOptions: PackagerOptio
delete info.DTSDKBuild
delete info.DTSDKName
delete info.DTCompiler
delete info.NSAllowsArbitraryLoads
// test value
if (info.LSMinimumSystemVersion !== "10.12.0") {
delete info.LSMinimumSystemVersion
Expand Down

0 comments on commit 930dc8d

Please sign in to comment.