Fix preprocessor for ethernet on-demand
This commit is contained in:
parent
413b5c3996
commit
3ad59c1f01
|
@ -63,7 +63,7 @@ private extension Profile.OnDemand {
|
||||||
rules.append(cellularRule())
|
rules.append(cellularRule())
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#if os(macOS)
|
#if targetEnvironment(macCatalyst) || os(macOS)
|
||||||
if Utils.hasEthernet() && withEthernetNetwork {
|
if Utils.hasEthernet() && withEthernetNetwork {
|
||||||
if let rule = ethernetRule() {
|
if let rule = ethernetRule() {
|
||||||
rules.append(rule)
|
rules.append(rule)
|
||||||
|
@ -123,7 +123,7 @@ private extension Profile.OnDemand {
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if os(macOS)
|
#if targetEnvironment(macCatalyst) || os(macOS)
|
||||||
func ethernetRule() -> NEOnDemandRule? {
|
func ethernetRule() -> NEOnDemandRule? {
|
||||||
guard let compatibleEthernet = NEOnDemandRuleInterfaceType.compatibleEthernet else {
|
guard let compatibleEthernet = NEOnDemandRuleInterfaceType.compatibleEthernet else {
|
||||||
return nil
|
return nil
|
||||||
|
|
Loading…
Reference in New Issue