Changeset 2507241
- Timestamp:
- 04/01/2021 08:37:39 AM (5 years ago)
- Location:
- pureclarity-for-woocommerce/trunk
- Files:
-
- 15 edited
-
includes/admin/class-pureclarity-signup.php (modified) (1 diff)
-
includes/class-pureclarity-settings.php (modified) (1 diff)
-
includes/php-sdk/src/PureClarity/Api/Delete/Submit.php (modified) (1 diff)
-
includes/php-sdk/src/PureClarity/Api/Delta/Base.php (modified) (1 diff)
-
includes/php-sdk/src/PureClarity/Api/Feed/Transfer.php (modified) (1 diff)
-
includes/php-sdk/src/PureClarity/Api/Feedback/Submit.php (modified) (1 diff)
-
includes/php-sdk/src/PureClarity/Api/Info/Dashboard.php (modified) (1 diff)
-
includes/php-sdk/src/PureClarity/Api/NextSteps/Complete.php (modified) (1 diff)
-
includes/php-sdk/src/PureClarity/Api/Signup/AddStore/Processor.php (modified) (1 diff)
-
includes/php-sdk/src/PureClarity/Api/Signup/Status/Processor.php (modified) (1 diff)
-
includes/php-sdk/src/PureClarity/Api/Signup/Submit/Processor.php (modified) (1 diff)
-
includes/public/class-pureclarity-bmz.php (modified) (2 diffs)
-
includes/public/class-pureclarity-public.php (modified) (1 diff)
-
pureclarity.php (modified) (2 diffs)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
pureclarity-for-woocommerce/trunk/includes/admin/class-pureclarity-signup.php
r2456271 r2507241 109 109 $this->process_auto_signup( $response['response'] ); 110 110 $result['success'] = true; 111 } elseif ( $response['error '] ) {112 $result['error'] = $response['error'];111 } elseif ( $response['errors'] ) { 112 $result['error'] = implode( ' | ', $response['errors'] ); 113 113 } 114 114 -
pureclarity-for-woocommerce/trunk/includes/class-pureclarity-settings.php
r2403275 r2507241 92 92 return true; 93 93 case 'admin': 94 return current_user_can( ' administrator' ) || defined( 'DOING_CRON' );94 return current_user_can( 'edit_pages' ) || defined( 'DOING_CRON' ); 95 95 } 96 96 return false; -
pureclarity-for-woocommerce/trunk/includes/php-sdk/src/PureClarity/Api/Delete/Submit.php
r2403275 r2507241 81 81 $body = $curl->getBody(); 82 82 83 if ($status !== 200) {83 if ($status < 200 || $status > 299) { 84 84 throw new Exception( 85 85 'Error: HTTP ' . $status . ' Response | ' . -
pureclarity-for-woocommerce/trunk/includes/php-sdk/src/PureClarity/Api/Delta/Base.php
r2403275 r2507241 167 167 $body = $curl->getBody(); 168 168 169 if ($status !== 200) {169 if ($status < 200 || $status > 299) { 170 170 throw new Exception( 171 171 'Error: HTTP ' . $status . ' Response | ' . -
pureclarity-for-woocommerce/trunk/includes/php-sdk/src/PureClarity/Api/Feed/Transfer.php
r2403275 r2507241 145 145 $body = $curl->getBody(); 146 146 147 if ($status !== 200) {147 if ($status < 200 || $status > 299) { 148 148 throw new Exception( 149 149 'Error: HTTP ' . $status . ' Response | ' . -
pureclarity-for-woocommerce/trunk/includes/php-sdk/src/PureClarity/Api/Feedback/Submit.php
r2403275 r2507241 88 88 $body = $curl->getBody(); 89 89 90 if ($status !== 200) {90 if ($status < 200 || $status > 299) { 91 91 throw new Exception( 92 92 'Error: HTTP ' . $status . ' Response | ' . -
pureclarity-for-woocommerce/trunk/includes/php-sdk/src/PureClarity/Api/Info/Dashboard.php
r2403275 r2507241 76 76 $body = $curl->getBody(); 77 77 78 if ($status !== 200) {78 if ($status < 200 || $status > 299) { 79 79 throw new Exception( 80 80 'Error: HTTP ' . $status . ' Response | ' . -
pureclarity-for-woocommerce/trunk/includes/php-sdk/src/PureClarity/Api/NextSteps/Complete.php
r2403275 r2507241 76 76 $body = $curl->getBody(); 77 77 78 if ($status !== 200) {78 if ($status < 200 || $status > 299) { 79 79 throw new Exception( 80 80 'Error: HTTP ' . $status . ' Response | ' . -
pureclarity-for-woocommerce/trunk/includes/php-sdk/src/PureClarity/Api/Signup/AddStore/Processor.php
r2456270 r2507241 40 40 $result['errors'] = $this->processErrors($result['response'], $response); 41 41 42 if ($response['status'] === 200) {42 if ($response['status'] >= 200 && $response['status'] <= 299) { 43 43 $result['success'] = true; 44 44 } -
pureclarity-for-woocommerce/trunk/includes/php-sdk/src/PureClarity/Api/Signup/Status/Processor.php
r2403275 r2507241 93 93 { 94 94 $complete = false; 95 if ( $response['status'] === 200&&95 if (($response['status'] >= 200 && $response['status'] <= 299) && 96 96 $this->isResponseBodyValid($response['response']) && 97 97 $response['response']['Complete'] === true -
pureclarity-for-woocommerce/trunk/includes/php-sdk/src/PureClarity/Api/Signup/Submit/Processor.php
r2403275 r2507241 40 40 $result['errors'] = $this->processErrors($result['response'], $response); 41 41 42 if ($response['status'] === 200) {42 if ($response['status'] >= 200 && $response['status'] <= 299) { 43 43 $result['success'] = true; 44 44 } -
pureclarity-for-woocommerce/trunk/includes/public/class-pureclarity-bmz.php
r2403275 r2507241 62 62 */ 63 63 public function init() { 64 add_shortcode( 'pureclarity-bmz', array( $this, 'pureclarity_render_bmz' ) ); 65 add_action( 'template_redirect', array( $this, 'render_bmzs' ), 10, 1 ); 64 if ( $this->settings->is_pureclarity_enabled() ) { 65 add_shortcode( 'pureclarity-bmz', array( $this, 'pureclarity_render_bmz' ) ); 66 add_action( 'template_redirect', array( $this, 'render_bmzs' ), 10, 1 ); 67 } else { 68 add_shortcode( 'pureclarity-bmz', array( $this, 'pureclarity_render_empty_bmz' ) ); 69 } 66 70 } 67 71 … … 370 374 ) 371 375 ); 376 } 377 378 /** 379 * Renders an empty zone (for when PC is disabled and shortcodes exist). 380 * 381 * @return string 382 */ 383 public function pureclarity_render_empty_bmz() { 384 return ''; 372 385 } 373 386 -
pureclarity-for-woocommerce/trunk/includes/public/class-pureclarity-public.php
r2403275 r2507241 57 57 add_action( 'wp_enqueue_scripts', array( $this, 'register_assets' ) ); 58 58 $this->configuration_display->init(); 59 $this->bmz->init();60 59 } 60 $this->bmz->init(); 61 61 } 62 62 -
pureclarity-for-woocommerce/trunk/pureclarity.php
r2477237 r2507241 8 8 * Description: Use PureClarity's wide range of ecommerce personalisation features to create engaging online shopping experiences for your customers. Drive revenue, average order value, conversion rate and customer loyalty. 9 9 * Plugin URI: https://www.pureclarity.com 10 * Version: 3.1. 010 * Version: 3.1.1 11 11 * Author: PureClarity 12 12 * Author URI: https://www.pureclarity.com/?utm_source=marketplace&utm_medium=woocommerce&utm_campaign=aboutpureclarity … … 21 21 22 22 // Set version and path constants. 23 define( 'PURECLARITY_VERSION', '3.1. 0' );23 define( 'PURECLARITY_VERSION', '3.1.1' ); 24 24 define( 'PURECLARITY_DB_VERSION', 1 ); 25 25 -
pureclarity-for-woocommerce/trunk/readme.txt
r2477237 r2507241 4 4 Requires at least: 4.7 5 5 Tested up to: 5.6.1 6 Stable tag: 3.1. 06 Stable tag: 3.1.1 7 7 License: GPLv3 or later 8 8 License URI: https://www.gnu.org/licenses/gpl.html … … 189 189 = 3.1.0 = 190 190 * Added ability to modify feed data using add_filter 191 192 = 3.1.1 = 193 * Tweaking admin only mode so that anyone who has "edit page" permissions can see Zones on the frontend 194 * Fixed an issue with shortcodes displaying to customers when in admin-only mode 195 * Fixing undefined index error being logged on signup
Note: See TracChangeset
for help on using the changeset viewer.