Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

authors_short doesn't work as expected #62

Open
2martens opened this issue Mar 16, 2016 · 0 comments
Open

authors_short doesn't work as expected #62

2martens opened this issue Mar 16, 2016 · 0 comments

Comments

@2martens
Copy link

authors_short is replaced with comma-separated list of surnames not with the expected format <first name> et al. After a lot of debugging I found out why that is the case.

The command authors = [a.split(", ")[0].trim() for a in authors.split(" and ")] results in an array with one child element that contains the array with the author names. Therefore the length of the first array is always 1, which means that 'et al.' is never appended. Since the authors variable is an array containing an array, the join command in the else clause doesn't do what is expected either.

After adding authors = authors[0] directly after the previously shown command, the behaviour is as expected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant