MCPcopy Index your code
hub / github.com/refined-github/refined-github / cleanPrCommitTitle

Function cleanPrCommitTitle

source/helpers/pr-commit-cleaner.ts:5–7  ·  view source on GitHub ↗
(commitTitle: string, pr: number)

Source from the content-addressed store, hash-verified

3@example 'Something done (#123)' => 'Something done'
4*/
5export default function cleanPrCommitTitle(commitTitle: string, pr: number): string {
6 return commitTitle.replace(new RegExp(String.raw`\(#${pr}\)\s*$`), '').trim();
7}

Callers 2

updatePrTitleFunction · 0.85

Calls 1

replaceMethod · 0.80

Tested by

no test coverage detected