unifi-ddns
unifi-ddns copied to clipboard
TypeError: Cannot set properties of undefined (setting 'content') when record does not exist
If you try and use this before creating a record, it returns an error:
$ curl -u "example.com:redacted" "https://ddns.example.workers.dev/update?ip=192.168.0.1&hostname=ddns.example.com"
TypeError: Cannot set properties of undefined (setting 'content')
at Cloudflare.updateRecord (worker.js:183:22)
at informAPI (worker.js:65:35)
at async handleRequest (worker.js:30:26)
May just want to update the README.md to indicate the dns record you are using must be created or already exist with a previous value.
Other than that, this worked great. Thanks!
Thanks for reporting the issue! Please submit a merge request, and I'll close this issue out
Fixed by #31