Open pronob1010 opened 1 week ago
The StoreController
class in includes/REST/StoreController.php
has been updated to enhance its REST API functionality. New optional parameters for the create_store
and check_store_availability
endpoints have been introduced, allowing for more detailed data handling and validation. The registration of routes has been modified to incorporate these changes, with refined error handling to ensure structured responses based on parameter validity.
File Path | Change Summary |
---|---|
includes/REST/StoreController.php | - Updated create_store method to include new optional parameters: user_login , email , store_name , social , payment , phone , show_email , address , location , banner_id , icon , gravatar_id , enable_tnc , store_tnc , show_min_order_discount , store_seo , store_open_close , notify_vendor . - Updated check_store_availability method to include optional parameters: store_slug , username , email . - Adjusted types for show_email , enable_tnc , and show_min_order_discount from boolean to string. - Enhanced error handling in check_store_availability method. |
QA approved
, :+1: Dev Review Done
, Upcoming Release
🐰 In the store where bunnies play,
New routes and checks have come our way.
With usernames and emails in sight,
Availability checks now feel just right!
Hop along, let’s celebrate,
A better API, oh, isn’t it great? 🌟
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
All Submissions:
Changes proposed in this Pull Request:
Related Pull Request(s)
Closes
How to test the changes in this Pull Request:
Changelog entry
Missing args for several endpoints in the REST API schema
Fixes missing arguments in the REST API schema for multiple endpoints, enhancing the schema definition and improving data validation.
Before Changes
Describe the issue before changes with screenshots(s).
After Changes
Describe the issue after changes with screenshot(s).
Feature Video (optional)
Link of detailed video if this PR is for a feature.
PR Self Review Checklist:
FOR PR REVIEWER ONLY:
Summary by CodeRabbit
New Features
check_store_availability
endpoint with optional parameters for store slugs, usernames, and email checks.create_store
endpoint to accept additional parameters for improved store management, including user login, email, and store details.Bug Fixes
check_store_availability
method, ensuring accurate responses for username and email availability.