Skip to content

Commit e68e4fc

Browse files
authored
fix: workPeriod update
1 parent b82f8c3 commit e68e4fc

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

src/services/WorkPeriodService.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -280,9 +280,6 @@ async function updateWorkPeriod (currentUser, id, data) {
280280
throw new errors.BadRequestError(`Maximum allowed daysWorked is (${thisWeek.daysWorked})`)
281281
}
282282
data.paymentStatus = helper.calculateWorkPeriodPaymentStatus(_.assign({}, oldValue, data))
283-
if (oldValue.paymentStatus === data.paymentStatus) {
284-
return oldValue
285-
}
286283
data.updatedBy = await helper.getUserId(currentUser.userId)
287284
const updated = await workPeriod.update(data)
288285
await helper.postEvent(config.TAAS_WORK_PERIOD_UPDATE_TOPIC, updated.toJSON(), { oldValue: oldValue, key: `resourceBooking.id:${updated.resourceBookingId}` })

0 commit comments

Comments
 (0)