Skip to content

Commit e1e5a06

Browse files
committed
fix
1 parent e2b7812 commit e1e5a06

File tree

1 file changed

+5
-11
lines changed

1 file changed

+5
-11
lines changed

apps/sim/blocks/blocks/workday.ts

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -349,24 +349,18 @@ Output: {"businessTitle": "Senior Engineer"}`,
349349
config: {
350350
tool: (params) => `workday_${params.operation}`,
351351
params: (params) => {
352-
const {
353-
operation,
354-
orgType,
355-
fields,
356-
positionId,
357-
jobProfileId,
358-
locationId,
359-
managerId,
360-
...rest
361-
} = params
352+
const { operation, orgType, fields, jobProfileId, locationId, managerId, ...rest } = params
362353

363354
if (rest.limit != null && rest.limit !== '') rest.limit = Number(rest.limit)
364355
if (rest.offset != null && rest.offset !== '') rest.offset = Number(rest.offset)
365356

366357
if (orgType) rest.type = orgType
367358

368359
if (operation === 'change_job') {
369-
if (positionId) rest.newPositionId = positionId
360+
if (rest.positionId) {
361+
rest.newPositionId = rest.positionId
362+
rest.positionId = undefined
363+
}
370364
if (jobProfileId) rest.newJobProfileId = jobProfileId
371365
if (locationId) rest.newLocationId = locationId
372366
if (managerId) rest.newManagerId = managerId

0 commit comments

Comments
 (0)