Skip to content

Fix weight entry validation for imperial units - #2434

Open
carolmnogai wants to merge 1 commit into
wger-project:masterfrom
carolmnogai:fix/weight-limit-imperial-units
Open

Fix weight entry validation for imperial units#2434
carolmnogai wants to merge 1 commit into
wger-project:masterfrom
carolmnogai:fix/weight-limit-imperial-units

Conversation

@carolmnogai

Copy link
Copy Markdown

Proposed Changes

  • Fix weight entry validation for users using imperial units (lb) by converting submitted values to kilograms before applying the stored kg limits.
  • Add API tests covering successful imperial weight submission and rejection of values that exceed the kg storage limit after conversion.

Related Issue(s)

Closes #2374

Please check that the PR fulfills these requirements

  • Tests for the changes have been added (for bug fixes / features)
  • Code has been formatted to avoid unnecessary diffs (ruff format && isort .)
  • If the feature is big enough or if there are manual steps needed (deployment
    changes etc.), write a small writeup in CHANGELOG.md

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.

Max Weight Limit

1 participant