summaryrefslogtreecommitdiff
path: root/lib/dns.js
diff options
context:
space:
mode:
authorcjihrig <cjihrig@gmail.com>2016-08-18 17:15:37 -0400
committerJames M Snell <jasnell@gmail.com>2016-08-22 11:07:05 -0700
commit013d76cb734aa6deb4f468395960fb9d985cd8f5 (patch)
tree5fdd55ae4b558a186a191c8324274f0a44dbb5d6 /lib/dns.js
parent3a43568020db762dea915122ed662e712a4a5781 (diff)
downloadandroid-node-v8-013d76cb734aa6deb4f468395960fb9d985cd8f5.tar.gz
android-node-v8-013d76cb734aa6deb4f468395960fb9d985cd8f5.tar.bz2
android-node-v8-013d76cb734aa6deb4f468395960fb9d985cd8f5.zip
dns: remove makeAsync() function check
makeAsync() is an internal method in the dns module. All of the functions that call makeAsync() have already validated that the callback is a function. This commit removes a redundant typeof function check. PR-URL: https://github.com/nodejs/node/pull/8170 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com>
Diffstat (limited to 'lib/dns.js')
-rw-r--r--lib/dns.js3
1 files changed, 0 insertions, 3 deletions
diff --git a/lib/dns.js b/lib/dns.js
index 3fd5184d83..7c76aebb97 100644
--- a/lib/dns.js
+++ b/lib/dns.js
@@ -56,9 +56,6 @@ function errnoException(err, syscall, hostname) {
// callback.immediately = true;
// }
function makeAsync(callback) {
- if (typeof callback !== 'function') {
- return callback;
- }
return function asyncCallback() {
if (asyncCallback.immediately) {
// The API already returned, we can invoke the callback immediately.