Skip to content

Commit 91833f6

Browse files
committed
fixes
1 parent 61047ea commit 91833f6

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

components/workday/actions/update-mentorship/update-mentorship.mjs

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ export default {
3737
type: "string",
3838
label: "Start Date",
3939
description: "Updated start date. Example: `2025-10-18T07:00:00.000Z`",
40-
optional: true,
4140
},
4241
endDate: {
4342
type: "string",
@@ -53,17 +52,14 @@ export default {
5352
},
5453
},
5554
async run({ $ }) {
56-
const data = {};
55+
const data = {
56+
startDate: this.startDate,
57+
};
5758
if (this.comment) data.comment = this.comment;
5859
if (this.purpose) data.purpose = this.purpose;
5960
if (this.endDate) data.endDate = this.endDate;
60-
if (this.startDate) data.startDate = this.startDate;
6161
if (this.descriptor) data.descriptor = this.descriptor;
6262

63-
if (Object.keys(data).length === 0) {
64-
throw new ConfigurationError("At least one field to update must be provided.");
65-
}
66-
6763
const response = await this.workday.updateMentorship({
6864
id: this.mentorshipId,
6965
data,

0 commit comments

Comments
 (0)