Skip to content

PM-1201 - sync payments with legacy #60

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
May 21, 2025
Merged

Conversation

vas3a
Copy link
Collaborator

@vas3a vas3a commented May 20, 2025

https://topcoder.atlassian.net/browse/PM-1201 - Sync payment status to legacy/Informix

@vas3a vas3a requested a review from kkartunov May 20, 2025 12:12
),
);
}
}
});

if (transactions.length > 0) {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

FYI - needed to update the way the DBtransaction is handled from batch transactions to one big transaction in order to be able to fail the transaction if the legacy update failed (this is happening only for admin updates only, for withdraw, we're just logging the error).

Copy link
Contributor

@kkartunov kkartunov left a comment

Choose a reason for hiding this comment

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

Looks good.

@vas3a vas3a merged commit 41b95c1 into dev May 21, 2025
1 check passed
@vas3a vas3a deleted the PM-1201_sync-payments-with-legacy branch May 21, 2025 08:34
}

const payoutData: AdminPaymentUpdateData = {
userId: +winning.winner_id,

Choose a reason for hiding this comment

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

high
correctness
Ensure that winning.winner_id is always a valid number before using the unary plus (+) operator for type coercion. If winning.winner_id can be null or undefined, this could lead to unexpected results. Consider adding validation or a default value to handle such cases.

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