Skip to content

Commit

Permalink
Simplify hasGateway check
Browse files Browse the repository at this point in the history
  • Loading branch information
keeshux committed Oct 26, 2022
1 parent 7b6aca4 commit 5913b80
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,10 @@ extension NetworkSettingsBuilder {

var hasGateway: Bool {
var hasGateway = false
if isIPv4Gateway && computedIPv4Settings != nil {
if isIPv4Gateway && remoteOptions.ipv4 != nil {
hasGateway = true
}
if isIPv6Gateway && computedIPv6Settings != nil {
if isIPv6Gateway && remoteOptions.ipv6 != nil {
hasGateway = true
}
return hasGateway
Expand Down

0 comments on commit 5913b80

Please sign in to comment.