From 4b3835925e87706c66f88efc4d94dadd3ce0db1c Mon Sep 17 00:00:00 2001 From: lamo2k123 Date: Wed, 26 Apr 2017 21:02:53 +0300 Subject: [PATCH] fixed method 'check' error 'format' of undefined (#1424) * fixed method 'check' error 'format' of undefined * Added normalizeOptions --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index e6348e70..834896c2 100644 --- a/index.js +++ b/index.js @@ -106,7 +106,7 @@ module.exports = { }, check: function(text, opts) { try { - const formatted = this.format(text, opts); + const formatted = formatWithShebang(text, normalizeOptions(opts)); return formatted === text; } catch (e) { return false;