Skip to content
Snippets Groups Projects
Commit 7a6bcfcf authored by Rhys Arkins's avatar Rhys Arkins
Browse files

fix: handle undefined depType in onboarding PR

parent 19e35ffe
No related branches found
No related tags found
No related merge requests found
...@@ -38,7 +38,11 @@ function getPrList(config) { ...@@ -38,7 +38,11 @@ function getPrList(config) {
} else { } else {
prDesc += upgrade.depName.replace(prTitleRe, '@​$1'); prDesc += upgrade.depName.replace(prTitleRe, '@​$1');
} }
prDesc += ` in \`${upgrade.depType}\` `; if (upgrade.depType) {
prDesc += ` in \`${upgrade.depType}\` `;
} else {
prDesc += ' ';
}
if (!upgrade.isPin) { if (!upgrade.isPin) {
prDesc += `from \`${upgrade.currentVersion}\` `; prDesc += `from \`${upgrade.currentVersion}\` `;
} }
......
...@@ -10,7 +10,7 @@ With your current configuration, Renovate will create 2 Pull Requests: ...@@ -10,7 +10,7 @@ With your current configuration, Renovate will create 2 Pull Requests:
- Branch name: \`renovate/pin-dependencies\` - Branch name: \`renovate/pin-dependencies\`
- Pins [a](https://a) in \`devDependencies\` to \`1.1.0\` - Pins [a](https://a) in \`devDependencies\` to \`1.1.0\`
- Pins b in \`devDependencies\` to \`1.5.3\` - Pins b to \`1.5.3\`
2. **Update a to v2** 2. **Update a to v2**
......
...@@ -45,7 +45,6 @@ describe('workers/repository/onboarding/pr/pr-list', () => { ...@@ -45,7 +45,6 @@ describe('workers/repository/onboarding/pr/pr-list', () => {
{ {
isPin: true, isPin: true,
depName: 'b', depName: 'b',
depType: 'devDependencies',
newVersion: '1.5.3', newVersion: '1.5.3',
}, },
], ],
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment