From b4c8fdc56a138e611ce829c558a7364b4cafcc5f Mon Sep 17 00:00:00 2001 From: Shan Carter Date: Fri, 1 Dec 2017 15:38:04 -0800 Subject: [PATCH] No authors bugfix --- src/helpers/citation.js | 1 + src/transforms/citation.js | 1 + 2 files changed, 2 insertions(+) diff --git a/src/helpers/citation.js b/src/helpers/citation.js index a419441..3b31ca4 100644 --- a/src/helpers/citation.js +++ b/src/helpers/citation.js @@ -40,6 +40,7 @@ export function inline_cite_long(keys){ } function author_string(ent, template, sep, finalSep){ + if (ent.author == null) { return ''; } var names = ent.author.split(' and '); let name_strings = names.map(name => { name = name.trim(); diff --git a/src/transforms/citation.js b/src/transforms/citation.js index cde18ca..b45d47b 100644 --- a/src/transforms/citation.js +++ b/src/transforms/citation.js @@ -95,6 +95,7 @@ export default function(dom, data) { } function author_string(ent, template, sep, finalSep){ + if (ent.author == null) { return ''; } var names = ent.author.split(' and '); let name_strings = names.map(name => { name = name.trim();