Kong / lua-resty-dns-client

Lua DNS client, load balancer, and utility library
http://kong.github.io/lua-resty-dns-client/topics/README.md.html
Apache License 2.0
152 stars 52 forks source link

fix(base) avoid a crash when self.lastQuery is not set #82

Closed hishamhm closed 4 years ago

hishamhm commented 4 years ago

I cannot reproduce this easily, but I've had a crash in the logs caused by attempting to dereference self.lastQuery.expire when self.lastQuery was nil.

Patched it like this to match the coding style present in this module.