-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Spree::Api:LineItemsController#create handling validation errors
Before, #create was expecting that the LineItem instance would have errors if failed to be created due to validation errors. However, #add actually raises ActiveRecord::RecordInvalid: Validation failed, so this endpoint could have never handled validation errors correctly.
- Loading branch information
1 parent
afa4d89
commit 5946a34
Showing
2 changed files
with
14 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters