screwdriver-api 8.0.146 → 8.0.147

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "screwdriver-api",
3
- "version": "8.0.146",
3
+ "version": "8.0.147",
4
4
  "description": "API server for the Screwdriver.cd service",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -71,12 +71,9 @@ module.exports = () => ({
71
71
  // Therefore, you should not specify a parentEventId in the payload except when using RESTART.
72
72
  // Prevents metadata from transferring when Start from a specific event
73
73
  if (parentEventId) {
74
- // eslint-disable-next-line default-case
75
- switch (startAction) {
76
- case 'RESTART_FROM_EVENT':
77
- case 'RESTART_FROM_BUILD': {
78
- payload.parentEventId = parentEventId;
79
- }
74
+ payload.parentEventId = parentEventId;
75
+ if (startAction === 'START_FROM_LATEST_COMMIT' || startAction === 'START_FROM_EVENT') {
76
+ delete payload.parentEventId;
80
77
  }
81
78
  }
82
79