Skip to content

Commit

Permalink
initial attempt
Browse files Browse the repository at this point in the history
  • Loading branch information
mircea-pavel-anton committed Jan 4, 2025
1 parent bd69e30 commit 25d634f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/mikrotik/record.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,8 @@ func (r *DNSRecord) toExternalDNSEndpoint() (*endpoint.Endpoint, error) {
// ============================================================================================
// Sanity checks
// ============================================================================================
if r.Name == "" {
return nil, fmt.Errorf("DNS record name cannot be empty")
if r.Name == "" && r.Regexp == "" {
return nil, fmt.Errorf("a DNS record must have either a Name or a RegExp defined")
}

//? Mikrotik assumes A-records are default and sometimes omits setting the type
Expand Down

0 comments on commit 25d634f

Please sign in to comment.