Skip to content

Commit 4539ef5

Browse files
committed
style: fix lint report
1 parent 3e1c43f commit 4539ef5

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

lib/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ function traverse (tree, cb) {
156156
function isSingleTag (tag, singleTags, singleRegExp) {
157157
if (singleRegExp.length) {
158158
for (var i = 0; i < singleRegExp.length; i++) {
159-
return tag.match(singleRegExp[i]) ? true : false
159+
return !!tag.match(singleRegExp[i])
160160
}
161161
}
162162

test/render.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -222,14 +222,14 @@ describe('PostHTML Render', function () {
222222
expect(render(fixture, options)).to.eql(expected)
223223
})
224224

225-
it('Custom {RegExp}', function() {
225+
it('Custom {RegExp}', function () {
226226
var options = { singleTags: [ /^%.*%$/ ] }
227227

228228
var fixture = { tag: '%=title%' }
229229
var expected = '<%=title%>'
230230

231231
expect(render(fixture, options)).to.eql(expected)
232-
});
232+
})
233233

234234
it('Attrs', function () {
235235
var options = { singleTags: [ 'rect' ] }

test/templates/parser.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)