Comparing version 1.4.1 to 1.4.2
@@ -10,3 +10,3 @@ 'use strict'; | ||
exports.default = function (text) { | ||
return text.map(function (_ref) { | ||
return (text || []).map(function (_ref) { | ||
var content = _ref.content; | ||
@@ -13,0 +13,0 @@ var href = _ref.href; |
import {element} from 'deku'; | ||
export default text => | ||
text.map(({content, href}) => | ||
(text || []).map(({content, href}) => | ||
href | ||
@@ -6,0 +6,0 @@ ? <a href={href}>{content}</a> |
{ | ||
"name": "embeds", | ||
"version": "1.4.1", | ||
"version": "1.4.2", | ||
"description": "Parse & render embeds", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
@@ -7,2 +7,3 @@ import test from 'ava'; | ||
import fixtures from './fixtures'; | ||
import renderText from '../lib/render-text'; | ||
@@ -236,1 +237,7 @@ const render = opts => string.render(_render(opts)); | ||
}); | ||
test('renderText()', t => { | ||
t.deepEqual(renderText(undefined), []); | ||
t.deepEqual(renderText(null), []); | ||
t.deepEqual(renderText([]), []); | ||
}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
99926
2452