Changeset 2738335
- Timestamp:
- 06/07/2022 03:07:44 AM (4 years ago)
- Location:
- wt-security/trunk
- Files:
-
- 5 edited
-
includes/templates/monitoring.html.twig (modified) (1 diff)
-
lib/Option.php (modified) (3 diffs)
-
readme.txt (modified) (1 diff)
-
src/Common.php (modified) (1 diff)
-
wt-security.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
wt-security/trunk/includes/templates/monitoring.html.twig
r2717857 r2738335 66 66 <div class="wtotem-tooltip__content"> 67 67 <p class="wtotem-tooltip__header">{{ 'Availability module'|trans }}</p> 68 <p class="wtotem-tooltip__text">{{ 'Check the performance of your site every minute. Stay informed about the problems of accessibility of the site instantly using any available types of notifications: SMS, Email, Telegram, Slack and many others.'|trans }}</p>68 <p class="wtotem-tooltip__text">{{ 'Check the performance of your site every minute. Stay informed about the problems.'|trans }}</p> 69 69 </div> 70 70 </div> -
wt-security/trunk/lib/Option.php
r2723090 r2738335 38 38 'all_hosts', 39 39 'plugin_version', 40 'sessions', 40 41 41 42 'host_id', … … 108 109 public static function setSessionOptions(array $options) { 109 110 110 foreach ($options as $option => $value) { 111 $_SESSION['wtotem.' . $option] = $value; 112 } 111 $sessions = self::getOption('sessions') ?: []; 112 $user_id = get_current_user_id(); 113 114 foreach ($options as $option => $value){ 115 $sessions[$user_id][$option] = $value; 116 } 117 118 self::setOptions(['sessions' => $sessions]); 119 113 120 return TRUE; 114 121 } … … 124 131 */ 125 132 public static function getSessionOption($option) { 126 if(!isset($_SESSION)) { 127 return[];128 }129 if(isset($_SESSION['wtotem.' . $option])){130 return $_SESSION['wtotem.' .$option];131 }132 else {133 return FALSE; 134 } 133 134 $sessions = self::getOption('sessions') ?: []; 135 $user_id = get_current_user_id(); 136 if(array_key_exists($user_id, $sessions) and array_key_exists($option, $sessions[$user_id])){ 137 return $sessions[$user_id][$option]; 138 } else { 139 return []; 140 } 141 135 142 } 136 143 -
wt-security/trunk/readme.txt
r2726827 r2738335 71 71 72 72 == Changelog == 73 = 2.4.8 = 74 * Session data storage has been changed 75 73 76 = 2.4.7 = 74 77 * Fixed a bug related to using the function str_contains -
wt-security/trunk/src/Common.php
r2724281 r2738335 10 10 if (defined('WEBTOTEM')) { 11 11 12 /**13 * Plugin's session start.14 */15 if(!session_id()) {16 session_start();17 }18 19 /**20 * Plugin's session close.21 */22 function wtotem_curl_before_request($curlhandle){23 session_write_close();24 }25 add_action( 'requests-curl.before_request','wtotem_curl_before_request', 9999 );26 12 27 13 /** -
wt-security/trunk/wt-security.php
r2726827 r2738335 8 8 * Text Domain: wtotem 9 9 * Domain Path: /lang 10 * Version: 2.4. 710 * Version: 2.4.8 11 11 * 12 12 * PHP version 7 … … 55 55 * Current version of the plugin's code. 56 56 */ 57 define('WEBTOTEM_VERSION', '2.4. 7');57 define('WEBTOTEM_VERSION', '2.4.8'); 58 58 59 59 /**
Note: See TracChangeset
for help on using the changeset viewer.