| @@ -3,9 +3,9 @@ | ||
| 3 | 3 | /** |
| 4 | 4 | * Plugin Name: Timetics - Appointment Booking Calendar & Scheduling System |
| 5 | 5 | * Plugin URI: https://arraytics.com/timetics/ |
| 6 | 6 | * Description: Schedule, Appointment and Seat Booking plugin. |
| 7 | - * Version: 1.0.57 | |
| 7 | + * Version: 1.0.64 | |
| 8 | 8 | * Requires at least: 5.2 |
| 9 | 9 | * Requires PHP: 7.3 |
| 10 | 10 | * Author: Arraytics |
| 11 | 11 | * Author URI: https://arraytics.com/ |
| @@ -55,9 +55,9 @@ | ||
| 55 | 55 | * |
| 56 | 56 | * @return string |
| 57 | 57 | */ |
| 58 | 58 | public static function get_version() { |
| 59 | - return '1.0.57'; | |
| 59 | + return '1.0.64'; | |
| 60 | 60 | } |
| 61 | 61 | |
| 62 | 62 | /** |
| 63 | 63 | * Requirements Array |
| @@ -117,8 +117,9 @@ | ||
| 117 | 117 | * @return void |
| 118 | 118 | */ |
| 119 | 119 | public function load_text_domain() { |
| 120 | 120 | $locale = determine_locale(); |
| 121 | + // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedHooknameFound -- WordPress core localization hook. | |
| 121 | 122 | $locale = apply_filters( 'plugin_locale', $locale, 'timetics' ); |
| 122 | 123 | $locale = apply_filters( 'timetics_plugin_locale', $locale, 'timetics' ); |
| 123 | 124 | |
| 124 | 125 | $mofile = 'timetics-' . $locale . '.mo'; |
| @@ -132,10 +133,14 @@ | ||
| 132 | 133 | if ( file_exists( WP_LANG_DIR . '/plugins/' . $mofile ) ) { |
| 133 | 134 | load_textdomain( 'timetics', WP_LANG_DIR . '/plugins/' . $mofile ); |
| 134 | 135 | } |
| 135 | 136 | |
| 136 | - // Loco "Author" location (plugin's own /languages/). | |
| 137 | - load_plugin_textdomain( 'timetics', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' ); | |
| 137 | + // Bundled translations remain available while WordPress loads language | |
| 138 | + // packs for this text domain automatically. | |
| 139 | + $bundled_mofile = plugin_dir_path( __FILE__ ) . 'languages/' . $mofile; | |
| 140 | + if ( file_exists( $bundled_mofile ) ) { | |
| 141 | + load_textdomain( 'timetics', $bundled_mofile ); | |
| 142 | + } | |
| 138 | 143 | } |
| 139 | 144 | |
| 140 | 145 | /** |
| 141 | 146 | * Initialize Plugin Modules |
| @@ -151,9 +156,8 @@ | ||
| 151 | 156 | |
| 152 | 157 | // block for showing banner. |
| 153 | 158 | require_once plugin_dir_path( __FILE__ ) . '/utils/notice/notice.php'; |
| 154 | 159 | require_once plugin_dir_path( __FILE__ ) . '/utils/banner/banner.php'; |
| 155 | - require_once plugin_dir_path( __FILE__ ) . '/utils/pro-awareness/pro-awareness.php'; | |
| 156 | 160 | |
| 157 | 161 | // Include the bootstrap file if not loaded. |
| 158 | 162 | if ( ! class_exists( 'Timetics\Bootstrap' ) ) { |
| 159 | 163 | require_once self::get_plugin_dir() . 'bootstrap.php'; |
| @@ -161,11 +165,8 @@ | ||
| 161 | 165 | |
| 162 | 166 | // init notice class. |
| 163 | 167 | \Oxaim\Libs\Notice::init(); |
| 164 | 168 | |
| 165 | - // init pro menu class. | |
| 166 | - \Wpmet\Libs\Pro_Awareness::init(); | |
| 167 | - | |
| 168 | 169 | // Initialize the bootstraper if exists. |
| 169 | 170 | if ( class_exists( 'Timetics\Bootstrap' ) ) { |
| 170 | 171 | |
| 171 | 172 | // Initialize all modules through plugins_loaded. |
| @@ -334,8 +335,9 @@ | ||
| 334 | 335 | * |
| 335 | 336 | * @return void |
| 336 | 337 | */ |
| 337 | 338 | public function deactivate() { |
| 339 | + wp_clear_scheduled_hook( 'timetics_cleanup_unpaid_bookings' ); | |
| 338 | 340 | } |
| 339 | 341 | |
| 340 | 342 | /** |
| 341 | 343 | * Quit Plugin Execution |