Changeset 3306099
- Timestamp:
- 06/04/2025 02:24:42 AM (9 months ago)
- Location:
- content-api
- Files:
-
- 4 edited
- 1 copied
-
tags/1.0.10 (copied) (copied from content-api/trunk)
-
tags/1.0.10/content-api.php (modified) (4 diffs)
-
tags/1.0.10/readme.txt (modified) (2 diffs)
-
trunk/content-api.php (modified) (4 diffs)
-
trunk/readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
content-api/tags/1.0.10/content-api.php
r3306098 r3306099 5 5 * Plugin URI: https://www.polyplugins.com/contact/ 6 6 * Description: Adds various endpoints to create content 7 * Version: 1.0. 97 * Version: 1.0.10 8 8 * Requires at least: 6.5 9 9 * Requires PHP: 7.4 … … 545 545 $stock_status = isset($fields['stock_status']) ? sanitize_text_field($fields['stock_status']) : ''; 546 546 $manage_stock = isset($fields['manage_stock']) ? sanitize_text_field($fields['manage_stock']) : ''; 547 $stock_quantity = isset($fields['stock_quantity']) ? intval($fields['stock_quantity']) : false; 547 548 $tags = isset($fields['tags']) && is_array($fields['tags']) ? array_map('sanitize_text_field', $fields['tags']) : array(); 548 549 $categories = isset($fields['categories']) && is_array($fields['categories']) ? array_map('sanitize_text_field', $fields['categories']) : array(); … … 583 584 return new WP_Error('product_not_found', 'Product not found', array('status' => 404)); 584 585 } 585 586 $stock_quantity = isset($fields['stock_quantity']) ? intval($fields['stock_quantity']) : false;587 586 588 587 if ($slug) { … … 776 775 $stock_status = isset($fields['stock_status']) ? sanitize_text_field($fields['stock_status']) : ''; 777 776 $manage_stock = isset($fields['manage_stock']) ? sanitize_text_field($fields['manage_stock']) : ''; 778 $stock_quantity = isset($fields['stock_quantity']) ? intval($fields['stock_quantity']) : '';777 $stock_quantity = isset($fields['stock_quantity']) ? intval($fields['stock_quantity']) : false; 779 778 $tags = isset($fields['tags']) && is_array($fields['tags']) ? array_map('sanitize_text_field', $fields['tags']) : array(); 780 779 $categories = isset($fields['categories']) && is_array($fields['categories']) ? array_map('sanitize_text_field', $fields['categories']) : array(); -
content-api/tags/1.0.10/readme.txt
r3306098 r3306099 3 3 Tags: content api, rest api, content, creative, api 4 4 Tested up to: 6.8 5 Stable tag: 1.0. 95 Stable tag: 1.0.10 6 6 Requires PHP: 7.4 7 7 License: GPLv3 … … 85 85 == Changelog == 86 86 87 = 1.0.10 = 88 * Updated: [Create Product](https://www.polyplugins.com/docs/content-api/api/create-product/) endpoint to not require quantity 89 87 90 = 1.0.9 = 88 91 * Added: [Get All Product IDs](https://www.polyplugins.com/docs/content-api/api/get-all-product-ids/) endpoint -
content-api/trunk/content-api.php
r3306098 r3306099 5 5 * Plugin URI: https://www.polyplugins.com/contact/ 6 6 * Description: Adds various endpoints to create content 7 * Version: 1.0. 97 * Version: 1.0.10 8 8 * Requires at least: 6.5 9 9 * Requires PHP: 7.4 … … 545 545 $stock_status = isset($fields['stock_status']) ? sanitize_text_field($fields['stock_status']) : ''; 546 546 $manage_stock = isset($fields['manage_stock']) ? sanitize_text_field($fields['manage_stock']) : ''; 547 $stock_quantity = isset($fields['stock_quantity']) ? intval($fields['stock_quantity']) : false; 547 548 $tags = isset($fields['tags']) && is_array($fields['tags']) ? array_map('sanitize_text_field', $fields['tags']) : array(); 548 549 $categories = isset($fields['categories']) && is_array($fields['categories']) ? array_map('sanitize_text_field', $fields['categories']) : array(); … … 583 584 return new WP_Error('product_not_found', 'Product not found', array('status' => 404)); 584 585 } 585 586 $stock_quantity = isset($fields['stock_quantity']) ? intval($fields['stock_quantity']) : false;587 586 588 587 if ($slug) { … … 776 775 $stock_status = isset($fields['stock_status']) ? sanitize_text_field($fields['stock_status']) : ''; 777 776 $manage_stock = isset($fields['manage_stock']) ? sanitize_text_field($fields['manage_stock']) : ''; 778 $stock_quantity = isset($fields['stock_quantity']) ? intval($fields['stock_quantity']) : '';777 $stock_quantity = isset($fields['stock_quantity']) ? intval($fields['stock_quantity']) : false; 779 778 $tags = isset($fields['tags']) && is_array($fields['tags']) ? array_map('sanitize_text_field', $fields['tags']) : array(); 780 779 $categories = isset($fields['categories']) && is_array($fields['categories']) ? array_map('sanitize_text_field', $fields['categories']) : array(); -
content-api/trunk/readme.txt
r3306098 r3306099 3 3 Tags: content api, rest api, content, creative, api 4 4 Tested up to: 6.8 5 Stable tag: 1.0. 95 Stable tag: 1.0.10 6 6 Requires PHP: 7.4 7 7 License: GPLv3 … … 85 85 == Changelog == 86 86 87 = 1.0.10 = 88 * Updated: [Create Product](https://www.polyplugins.com/docs/content-api/api/create-product/) endpoint to not require quantity 89 87 90 = 1.0.9 = 88 91 * Added: [Get All Product IDs](https://www.polyplugins.com/docs/content-api/api/get-all-product-ids/) endpoint
Note: See TracChangeset
for help on using the changeset viewer.