refactor(ui): prefer to use utility function
@@ -259,9 +259,7 @@ export function toUIIntegrationStepCollection(
if (step.stepKind === 'mapper') {
shouldEditDataMapper =
// if any of the prevous steps's output differ, any could be used in the mapping step
- steps
- .slice(0, position)
- .find((s) =>
+ getPreviousSteps(steps, position).find((s) =>
isMappingOutdated(
step.metadata?.updatedAt,
s.metadata?.outputUpdatedAt
