Plugin Directory

Changeset 3388248


Ignore:
Timestamp:
11/02/2025 05:31:31 AM (5 months ago)
Author:
alphanetbd
Message:

Allow WooCommerce registration OTP validation without checkout OTP

Location:
alpha-sms
Files:
48 added
4 edited

Legend:

Unmodified
Added
Removed
  • alpha-sms/trunk/README.txt

    r3362984 r3388248  
    55Tested up to: 6.8.2
    66Requires PHP: 5.6
    7 Stable tag: 1.0.12
     7Stable tag: 1.0.13
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    6060== Changelog ==
    6161
    62 = 1.0.12 =
     62= 1.0.13 =
    6363* Added a background processor so campaign SMS messages are queued individually and sent by scheduled jobs.
    6464* Aggregated campaign job results into concise admin notices that highlight failed numbers and the most recent error.
  • alpha-sms/trunk/alpha_sms.php

    r3362984 r3388248  
    1717 * Plugin URI:        https://sms.net.bd/plugins/wordpress
    1818 * Description:       WP 2FA Login. SMS OTP Verification for Registration and Login forms, WooCommerce SMS Notification for your shop orders.
    19  * Version:           1.0.12
     19 * Version:           1.0.13
    2020 * Author:            Alpha Net
    2121 * Author URI:        https://sms.net.bd/
     
    3636 * Rename this for your plugin and update it as you release new versions.
    3737 */
    38 define('ALPHA_SMS_VERSION', '1.0.12');
     38define('ALPHA_SMS_VERSION', '1.0.13');
    3939
    4040// plugin constants
  • alpha-sms/trunk/includes/class-alpha_sms.php

    r3362984 r3388248  
    7777            $this->version = ALPHA_SMS_VERSION;
    7878        } else {
    79             $this->version = '1.0.12';
     79            $this->version = '1.0.13';
    8080        }
    8181        $this->plugin_name = 'alpha_sms';
  • alpha-sms/trunk/public/class-alpha_sms-public.php

    r3362903 r3388248  
    590590    {
    591591
    592         $enable_guest_checkout = get_option('woocommerce_enable_guest_checkout');
    593         $enable_guest_checkout = $enable_guest_checkout === 'yes' ? true : false;
    594 
    595         if (!$this->pluginActive || !$this->options['otp_checkout'] || $enable_guest_checkout) {
    596             return $errors;
    597         }
     592                $enable_guest_checkout = get_option('woocommerce_enable_guest_checkout');
     593                $enable_guest_checkout = $enable_guest_checkout === 'yes' ? true : false;
     594
     595                $action_type = isset($_REQUEST['action_type']) ? sanitize_text_field($_REQUEST['action_type']) : '';
     596
     597                $shouldValidate = $this->pluginActive && (
     598                        (!empty($this->options['otp_checkout']) && !$enable_guest_checkout) ||
     599                        (!empty($this->options['wc_reg']) && $action_type === 'wc_reg') ||
     600                        (!empty($this->options['wp_reg']) && $action_type === 'wp_reg')
     601                );
     602
     603                if (!$shouldValidate) {
     604                        return $errors;
     605                }
    598606
    599607        if (
Note: See TracChangeset for help on using the changeset viewer.