Skip to content

Commit

Permalink
fix(#110): missing package import
Browse files Browse the repository at this point in the history
  • Loading branch information
Nicolas COUTIN committed Jan 11, 2019
1 parent fb5879a commit ed483ee
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/sitemap-item.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ const ut = require('./utils')
const fs = require('fs')
const err = require('./errors')
const builder = require('xmlbuilder')
const { isArray } = require('lodash/isArray')

function safeDuration (duration) {
if (duration < 0 || duration > 28800) {
throw new err.InvalidVideoDuration()
Expand Down Expand Up @@ -163,7 +165,7 @@ class SitemapItem {
videoxml.element('video:family_friendly', video.family_friendly)
}
if (video.tag) {
if (!_.isArray(video.tag)) {
if (!isArray(video.tag)) {
videoxml.element('video:tag', video.tag)
} else {
for (const tag of video.tag) {
Expand Down

0 comments on commit ed483ee

Please sign in to comment.