Skip to content

fix(PM-4133): Removed the availableForGigs for others#97

Merged
kkartunov merged 1 commit intodevelopfrom
pm-4133
Mar 11, 2026
Merged

fix(PM-4133): Removed the availableForGigs for others#97
kkartunov merged 1 commit intodevelopfrom
pm-4133

Conversation

@hentrymartin
Copy link
Collaborator

What's in this PR?

  • Removed the availableForGigs for others from traits endpoint, this trait is not used in frontend but openToWork is used but still leaving this for self users.

Ticket link - https://topcoder.atlassian.net/browse/PM-4133

if (item.traitId === 'personalization' && item.traits && item.traits.data) {
_.forEach(item.traits.data, (dataEntry) => {
delete dataEntry.links
delete dataEntry.availableForGigs

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[⚠️ correctness]
The deletion of availableForGigs from dataEntry should be conditional based on the context or requirements. Ensure that this field is not needed for any other logic or future use cases.

if (Array.isArray(dataEntry.personalization)) {
_.forEach(dataEntry.personalization, (each) => {
delete each.links
delete each.availableForGigs

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[⚠️ correctness]
The deletion of availableForGigs from each item in dataEntry.personalization should be validated to ensure it doesn't affect other parts of the application that might rely on this data.

@kkartunov kkartunov merged commit f8b06c3 into develop Mar 11, 2026
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants