From d0fffaf8c283b6282aa06e5497771e4af51f9d48 Mon Sep 17 00:00:00 2001 From: Eli Heady Date: Sat, 3 May 2025 08:21:44 -0400 Subject: [PATCH] BUGFIX: types fix: CAA_BUILDER accepts string[] or string for issue (#3546) --- commands/types/dnscontrol.d.ts | 2 +- .../language-reference/domain-modifiers/CAA_BUILDER.md | 4 ++-- pkg/js/helpers.js | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/commands/types/dnscontrol.d.ts b/commands/types/dnscontrol.d.ts index 7447bbcd5..220c4547c 100644 --- a/commands/types/dnscontrol.d.ts +++ b/commands/types/dnscontrol.d.ts @@ -469,7 +469,7 @@ declare function CAA(name: string, tag: "issue" | "issuewild" | "iodef", value: * * @see https://docs.dnscontrol.org/language-reference/domain-modifiers/caa_builder */ -declare function CAA_BUILDER(opts: { label?: string; iodef: string; iodef_critical?: boolean; issue: string[]; issue_critical?: boolean; issuewild: string[]; issuewild_critical?: boolean; ttl?: Duration }): DomainModifier; +declare function CAA_BUILDER(opts: { label?: string; iodef: string; iodef_critical?: boolean; issue: string[]|string; issue_critical?: boolean; issuewild: string[]|string; issuewild_critical?: boolean; ttl?: Duration }): DomainModifier; /** * WARNING: Cloudflare is removing this feature and replacing it with a new diff --git a/documentation/language-reference/domain-modifiers/CAA_BUILDER.md b/documentation/language-reference/domain-modifiers/CAA_BUILDER.md index a7d4b5b78..078d180a7 100644 --- a/documentation/language-reference/domain-modifiers/CAA_BUILDER.md +++ b/documentation/language-reference/domain-modifiers/CAA_BUILDER.md @@ -14,9 +14,9 @@ parameter_types: label: string? iodef: string iodef_critical: boolean? - issue: string[] + issue: string[]|string issue_critical: boolean? - issuewild: string[] + issuewild: string[]|string issuewild_critical: boolean? ttl: Duration? --- diff --git a/pkg/js/helpers.js b/pkg/js/helpers.js index 86ec7c5e0..985ba6487 100644 --- a/pkg/js/helpers.js +++ b/pkg/js/helpers.js @@ -1678,8 +1678,8 @@ function SPF_BUILDER(value) { // label: The DNS label for the CAA record. (default: '@') // iodef: The contact mail address. (optional) // iodef_critical: Boolean if sending report is required/critical. If not supported, certificate should be refused. (optional) -// issue: List of CAs which are allowed to issue certificates for the domain (creates one record for each). -// issuewild: Allowed CAs which can issue wildcard certificates for this domain. (creates one record for each) +// issue: List of CAs which are allowed to issue certificates for the domain (creates one record for each), or the string 'none'. +// issuewild: List of allowed CAs which can issue wildcard certificates for this domain, or the string 'none'. (creates one record for each) // ttl: The time for TTL, integer or string. (default: not defined, using DefaultTTL) function CAA_BUILDER(value) {