Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions pages/github/co-author.html
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,12 @@ <h1>GitHub Co-Author Generator</h1>
);
}

const coAuthorLine = `Co-authored-by: ${data.login} <${data.id}+${data.login}@users.noreply.github.com>`;
resultEditor.value = `\n\`\`\`\ncomment\n\n${coAuthorLine}\n\`\`\`\n`;
if (data.email) {
const coAuthor = `${data.name ? data.name : data.login} <${data.email}>`;
} else {
const coAuthor = `${data.name ? data.name : data.login} <${data.id}+${data.login}@users.noreply.github.com>`;
}
resultEditor.value = `\n\`\`\`\ncomment\n\nCo-authored-by: ${coAuthor}\n\`\`\`\n`;
Comment thread
casperdcl marked this conversation as resolved.
Outdated

// Update URL parameter
const newUrl = new URL(window.location.href);
Expand Down