Skip to content
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

feat: Return full updated items after upsert #764

Merged
merged 2 commits into from
Aug 14, 2024

Conversation

LautaroPetaccio
Copy link
Contributor

This PR changes the upsert endpoint to return the full item after upserting it.

@coveralls
Copy link

coveralls commented Aug 14, 2024

Pull Request Test Coverage Report for Build 10388330869

Details

  • 15 of 17 (88.24%) changed or added relevant lines in 3 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.3%) to 71.324%

Changes Missing Coverage Covered Lines Changed/Added Lines %
spec/utils.ts 6 8 75.0%
Totals Coverage Status
Change from base Build 10321049212: 0.3%
Covered Lines: 3085
Relevant Lines: 4174

💛 - Coveralls

if (catalystItems.length > 0) {
item = Bridge.mergeTPItem(dbItem, collection, catalystItems[0])
}
item = Bridge.mergeTPItem(
Copy link
Contributor

@cyaiox cyaiox Aug 14, 2024

Choose a reason for hiding this comment

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

should this validation kept?

catalystItems.length > 0

Copy link
Contributor Author

Choose a reason for hiding this comment

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

If there's no catalyst item, the mergeTPItem function will receive it as undefined, producing a full item without it.

@LautaroPetaccio LautaroPetaccio merged commit 9b61ca4 into master Aug 14, 2024
4 checks passed
@LautaroPetaccio LautaroPetaccio deleted the feat/return-full-updated-item-after-upsert branch August 14, 2024 14:34
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.

3 participants