Merge pull request #651 from foxytocin/enhancement

Enhancement of issue #649: also checking agains NULL in urlFilter
This commit is contained in:
Mike Cao 2021-05-12 19:28:22 -07:00 committed by GitHub
commit a06901336c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -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) {