Skip to content

Commit

Permalink
Merge pull request #651 from foxytocin/enhancement
Browse files Browse the repository at this point in the history
Enhancement of issue #649: also checking agains NULL in urlFilter
  • Loading branch information
mikecao authored May 13, 2021
2 parents d6c48fa + cfb13b2 commit a069013
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/filters.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { removeTrailingSlash, removeWWW, getDomainName } from './url';

export const urlFilter = (data, { raw }) => {
const isValidUrl = url => {
return url !== '' && !url.startsWith('#');
return url !== '' && url !== null && !url.startsWith('#');
};

if (raw) {
Expand Down

0 comments on commit a069013

Please sign in to comment.