From 00b27da6cca1c80643606b157989730355aeaabe Mon Sep 17 00:00:00 2001 From: Mathias Buus Date: Thu, 18 Feb 2016 13:15:35 -0800 Subject: [PATCH] allow null txt records --- index.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/index.js b/index.js index 1f8581d..7635a5a 100644 --- a/index.js +++ b/index.js @@ -171,6 +171,8 @@ rtxt.encode = function (data, buf, offset) { if (!offset) offset = 0 if (typeof data === 'string') data = Buffer(data) + if (!data) data = Buffer(0) + var oldOffset = offset offset += 2