Skip to content

Commit 3e1deea

Browse files
Cloudflare report error on create request if ZoneID not supplied
1 parent 0e98726 commit 3e1deea

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/Certify.Providers/DNS/Cloudflare/DnsProviderCloudflare.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,11 @@ private async Task<ActionResult> UpdateDnsRecord(string zoneId, DnsRecordCloudfl
281281

282282
public async Task<ActionResult> CreateRecord(DnsRecord request)
283283
{
284+
if (string.IsNullOrEmpty(request.ZoneId))
285+
{
286+
return new ActionResult("Zone ID not specified. Cannot create record", false);
287+
}
288+
284289
try
285290
{
286291
// check existing before creating new

0 commit comments

Comments
 (0)