Skip to content
Snippets Groups Projects
Commit d52a4c5c authored by Deucе's avatar Deucе 👌🏾
Browse files

Use this, not ctx in handlers.

parent 1111fb24
No related branches found
No related tags found
1 merge request!463MRC mods by Codefenix (2024-10-20)
...@@ -646,7 +646,7 @@ DNS.prototype.resolve = function(host, callback, thisObj) ...@@ -646,7 +646,7 @@ DNS.prototype.resolve = function(host, callback, thisObj)
this.AAAA.done = true; this.AAAA.done = true;
if (this.A.done) { if (this.A.done) {
if (this.final !== undefined) if (this.final !== undefined)
js.dispatchEvent(ctx.unique_id + '.final', this); js.dispatchEvent(this.unique_id + '.final', this);
else else
this.final_callback(this); this.final_callback(this);
} }
...@@ -675,7 +675,7 @@ DNS.prototype.resolve = function(host, callback, thisObj) ...@@ -675,7 +675,7 @@ DNS.prototype.resolve = function(host, callback, thisObj)
return; return;
this[rectype].addrs.push(ans.rdata); this[rectype].addrs.push(ans.rdata);
}, this); }, this);
if (ctx.callback !== undefined) if (this.callback !== undefined)
js.dispatchEvent(this.unique_id + '.resp'+rectype, this); js.dispatchEvent(this.unique_id + '.resp'+rectype, this);
else else
this['resp'+rectype+'_callback'](); this['resp'+rectype+'_callback']();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment