mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2025-02-24 07:33:03 +08:00
BUGFIX: PrettySort helper doesn't sort (#1838)
PrettySort doesn't call sort! Luckily the only code that calls this is the "get-zones" subcommand, and nobody noticed that the output isn't sorted. By making this change, people using "get-zones" to make their initial dnsconfig.js file will now find that their draft D() code is a little prettier.
This commit is contained in:
parent
5b95c099f6
commit
ec5c4abbd6
1 changed files with 1 additions and 0 deletions
|
@ -90,6 +90,7 @@ func PrettySort(records models.Records, origin string, defaultTTL uint32, commen
|
|||
}
|
||||
z.Records = nil
|
||||
z.Records = append(z.Records, records...)
|
||||
sort.Sort(z)
|
||||
return z
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue