summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/console.js3
-rw-r--r--test/parallel/test-console-table.js1
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/console.js b/lib/console.js
index 868b2f286b..de2d11afe1 100644
--- a/lib/console.js
+++ b/lib/console.js
@@ -327,8 +327,7 @@ Console.prototype.table = function(tabularData, properties) {
if (properties !== undefined && !ArrayIsArray(properties))
throw new ERR_INVALID_ARG_TYPE('properties', 'Array', properties);
- if (tabularData == null ||
- (typeof tabularData !== 'object' && typeof tabularData !== 'function'))
+ if (tabularData == null || typeof tabularData !== 'object')
return this.log(tabularData);
if (cliTable === undefined) cliTable = require('internal/cli_table');
diff --git a/test/parallel/test-console-table.js b/test/parallel/test-console-table.js
index 64e2533f17..2b63556aca 100644
--- a/test/parallel/test-console-table.js
+++ b/test/parallel/test-console-table.js
@@ -29,6 +29,7 @@ test(undefined, 'undefined\n');
test(false, 'false\n');
test('hi', 'hi\n');
test(Symbol(), 'Symbol()\n');
+test(function() {}, '[Function]\n');
test([1, 2, 3], `
┌─────────┬────────┐