Skip to content

Conversation

@vas3a
Copy link
Collaborator

@vas3a vas3a commented Oct 22, 2025

No description provided.

@vas3a vas3a merged commit ac81770 into dev Oct 22, 2025
1 check passed

async removePayment(paymentId: string, batchId: string) {
try {
await this.client.payment.remove(paymentId, batchId);

Choose a reason for hiding this comment

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

[⚠️ correctness]
Consider adding a check to ensure paymentId and batchId are valid before attempting to remove the payment. This can prevent unnecessary operations and potential errors if the IDs are invalid or undefined.

this.logger.debug(`Removed trolley payment with id ${paymentId}`);
} catch (error) {
this.logger.error(
`Failed to remove trolley payment: '${error.message}'!`,

Choose a reason for hiding this comment

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

[💡 readability]
The error logging message could be improved by including more context about the operation that failed. Consider specifying the operation name in the log message to make it clearer in the logs.

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