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

Spree::Variant.in_stock: Only show distinct variants #5860

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

mamhoff
Copy link
Contributor

@mamhoff mamhoff commented Sep 25, 2024

Summary

Without the .distinct added to this scope, it returns the same variant multiple times if there is stock in multiple stock locations.

Checklist

Check out our PR guidelines for more details.

The following are mandatory for all PRs:

@mamhoff mamhoff requested a review from a team as a code owner September 25, 2024 12:10
@github-actions github-actions bot added the changelog:solidus_core Changes to the solidus_core gem label Sep 25, 2024
Without the `.distinct` added to this scope, it returns the same variant
multiple times if there is stock in multiple stock locations.
Copy link

codecov bot commented Sep 25, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.23%. Comparing base (8182cb2) to head (b2f8e4f).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #5860   +/-   ##
=======================================
  Coverage   89.23%   89.23%           
=======================================
  Files         752      752           
  Lines       17510    17510           
=======================================
  Hits        15625    15625           
  Misses       1885     1885           
Flag Coverage Δ
89.23% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog:solidus_core Changes to the solidus_core gem
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants