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

Empty suffix leads to trailing comma #155

Closed
pkra opened this issue Mar 23, 2016 · 1 comment
Closed

Empty suffix leads to trailing comma #155

pkra opened this issue Mar 23, 2016 · 1 comment

Comments

@pkra
Copy link
Contributor

pkra commented Mar 23, 2016

It seems enough for

if (suffix) return [names.join(" "), suffix.textContent].join(", ");
to check if the suffix is non-empty.

@pkra
Copy link
Contributor Author

pkra commented Mar 23, 2016

This seems enough

if (suffix && !(suffix.textContent.trim() === "")) return [names.join(" "), suffix.textContent].join(", ");

pkra added a commit to pkra/lens that referenced this issue Mar 23, 2016
Check if suffix is empty; fixes elifesciences#155.
@pkra pkra mentioned this issue Mar 23, 2016
pkra added a commit to AmerMathSoc/lens that referenced this issue Apr 19, 2016
Check if suffix is empty; fixes elifesciences#155.
michael pushed a commit that referenced this issue Apr 20, 2016
@michael michael closed this as completed Jun 2, 2016
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

2 participants