New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sort DNS Records such that multiple records with same name are grouped #442
Comments
|
@Myrfion Let me know if I understand this correctly: |
@cychu42 sorry just seen your message on this one, the issue got resolved in your PR right? |
NOTE: @dadolhay suggests adding the value + name together as the sort key. You can talk to him for more info. |
const recordsSorted = records.sort(
(({subdomain: aSubdomain, type: aType}, {subdomain: bSubdomain, type: btype}) =>
[...aSubdomain].reverse().join('').localeCompare([...bSubdomain].reverse().join('')) ||
atype.localeCompare(btype)
);
This is not tested, you might need to change the compare order (like compare b with a instead of a with b) |
I only added restriction to not duplicate CNAME records, and restriction on other record type duplication is currently in place. |
In #438 we are moving to allow DNS Records of type
A
,AAAA
, andTXT
(i.e., notCNAME
) to have multiple values. Our current UI assumes this is always a single value. We need to make 2 changes:,
for exampleThe text was updated successfully, but these errors were encountered: