Skip to content

OBPIH-7579 Prevent QOH from being cleared after saving twice in a row#5624

Merged
kchelstowski merged 2 commits intorelease/0.9.6from
bug/OBPIH-7579-fix
Nov 14, 2025
Merged

OBPIH-7579 Prevent QOH from being cleared after saving twice in a row#5624
kchelstowski merged 2 commits intorelease/0.9.6from
bug/OBPIH-7579-fix

Conversation

@kchelstowski
Copy link
Collaborator

✨ Description of Change

Link to GitHub issue or Jira ticket:

Description:


📷 Screenshots & Recordings (optional)

@kchelstowski kchelstowski self-assigned this Nov 14, 2025
@github-actions github-actions bot added type: bug Addresses unintended behaviours of the app domain: frontend Changes or discussions relating to the frontend UI labels Nov 14, 2025
const mapPropertiesOfItemsToBeAdded = (item) => {
const itemQuantityCounted = item.quantityOnHand
// The truthiness check is not enough as 0 is a valid value that we want to save
const itemQuantityCounted = (item.quantityOnHand || item?.quantityOnHand === 0)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Don't you need to add a nullsafe operator in the first item.quantityOnHand?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The item can't be null/undefined, as this method is called as a callback/"transformer" in a .map function
Screenshot From 2025-11-14 13-06-47

Copy link
Collaborator

Choose a reason for hiding this comment

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

So the nullsafe that you added is also unnecessary

@codecov
Copy link

codecov bot commented Nov 14, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (release/0.9.6@a4dcf04). Learn more about missing BASE report.

Additional details and impacted files
@@               Coverage Diff               @@
##             release/0.9.6   #5624   +/-   ##
===============================================
  Coverage                 ?   8.51%           
  Complexity               ?    1127           
===============================================
  Files                    ?     712           
  Lines                    ?   45640           
  Branches                 ?   10913           
===============================================
  Hits                     ?    3887           
  Misses                   ?   41174           
  Partials                 ?     579           

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@kchelstowski kchelstowski merged commit cdaecac into release/0.9.6 Nov 14, 2025
7 checks passed
@kchelstowski kchelstowski deleted the bug/OBPIH-7579-fix branch November 14, 2025 12:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

domain: frontend Changes or discussions relating to the frontend UI type: bug Addresses unintended behaviours of the app

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants