Changeset 2813255
- Timestamp:
- 11/07/2022 07:54:42 AM (3 years ago)
- Location:
- logtivity
- Files:
-
- 66 added
- 7 edited
-
tags/2.0.1 (added)
-
tags/2.0.1/.gitignore (added)
-
tags/2.0.1/Admin (added)
-
tags/2.0.1/Admin/Logtivity_Admin.php (added)
-
tags/2.0.1/Admin/Logtivity_Dismiss_Notice_Controller.php (added)
-
tags/2.0.1/Admin/Logtivity_Log_Index_Controller.php (added)
-
tags/2.0.1/Admin/Logtivity_Options.php (added)
-
tags/2.0.1/Errors (added)
-
tags/2.0.1/Errors/Logtivity_Error_Log.php (added)
-
tags/2.0.1/Errors/Logtivity_Error_Logger.php (added)
-
tags/2.0.1/Errors/Logtivity_Stack_Trace.php (added)
-
tags/2.0.1/Errors/Logtivity_Stack_Trace_Snippet.php (added)
-
tags/2.0.1/Helpers (added)
-
tags/2.0.1/Helpers/Helpers.php (added)
-
tags/2.0.1/Helpers/Logtivity_Log_Global_Function.php (added)
-
tags/2.0.1/Helpers/Logtivity_Wp_User.php (added)
-
tags/2.0.1/Logs (added)
-
tags/2.0.1/Logs/Code_Snippets (added)
-
tags/2.0.1/Logs/Code_Snippets/Logtivity_Code_Snippets.php (added)
-
tags/2.0.1/Logs/Core (added)
-
tags/2.0.1/Logs/Core/Logtivity_Comment.php (added)
-
tags/2.0.1/Logs/Core/Logtivity_Core.php (added)
-
tags/2.0.1/Logs/Core/Logtivity_Meta.php (added)
-
tags/2.0.1/Logs/Core/Logtivity_Plugin.php (added)
-
tags/2.0.1/Logs/Core/Logtivity_Post.php (added)
-
tags/2.0.1/Logs/Core/Logtivity_Term.php (added)
-
tags/2.0.1/Logs/Core/Logtivity_Theme.php (added)
-
tags/2.0.1/Logs/Core/Logtivity_User.php (added)
-
tags/2.0.1/Logs/Download_Monitor (added)
-
tags/2.0.1/Logs/Download_Monitor/Logtivity_Download_Monitor.php (added)
-
tags/2.0.1/Logs/Easy_Digital_Downloads (added)
-
tags/2.0.1/Logs/Easy_Digital_Downloads/Logtivity_Abstract_Easy_Digital_Downloads.php (added)
-
tags/2.0.1/Logs/Easy_Digital_Downloads/Logtivity_Easy_Digital_Downloads.php (added)
-
tags/2.0.1/Logs/Easy_Digital_Downloads/Logtivity_Easy_Digital_Downloads_Recurring.php (added)
-
tags/2.0.1/Logs/Easy_Digital_Downloads/Logtivity_Easy_Digital_Downloads_Software_Licensing.php (added)
-
tags/2.0.1/Logs/Formidable (added)
-
tags/2.0.1/Logs/Formidable/Logtivity_Formidable.php (added)
-
tags/2.0.1/Logs/Formidable/Logtivity_FrmEntryFormatter.php (added)
-
tags/2.0.1/Logs/Logtivity_Abstract_Logger.php (added)
-
tags/2.0.1/Logs/Memberpress (added)
-
tags/2.0.1/Logs/Memberpress/Logtivity_Memberpress.php (added)
-
tags/2.0.1/Logs/WP_All_Import (added)
-
tags/2.0.1/Logs/WP_All_Import/Logtivity_WP_All_Import.php (added)
-
tags/2.0.1/Services (added)
-
tags/2.0.1/Services/Logtivity_Api.php (added)
-
tags/2.0.1/Services/Logtivity_Check_For_Disabled_Individual_Logs.php (added)
-
tags/2.0.1/Services/Logtivity_Logger.php (added)
-
tags/2.0.1/Services/Logtivity_Register_Site.php (added)
-
tags/2.0.1/Services/Logtivity_User_Logger_Trait.php (added)
-
tags/2.0.1/assets (added)
-
tags/2.0.1/assets/admin.css (added)
-
tags/2.0.1/assets/app.js (added)
-
tags/2.0.1/assets/logtivity-logo.svg (added)
-
tags/2.0.1/logtivity.php (added)
-
tags/2.0.1/readme.md (added)
-
tags/2.0.1/readme.txt (added)
-
tags/2.0.1/views (added)
-
tags/2.0.1/views/_admin-footer.php (added)
-
tags/2.0.1/views/_admin-header.php (added)
-
tags/2.0.1/views/_admin-sidebar.php (added)
-
tags/2.0.1/views/_log-show.php (added)
-
tags/2.0.1/views/_logs-loop.php (added)
-
tags/2.0.1/views/activation.php (added)
-
tags/2.0.1/views/log-index.php (added)
-
tags/2.0.1/views/settings.php (added)
-
tags/2.0.1/views/site-url-changed-notice.php (added)
-
trunk/Admin/Logtivity_Log_Index_Controller.php (modified) (1 diff)
-
trunk/Errors/Logtivity_Error_Log.php (modified) (2 diffs)
-
trunk/Logs/Core/Logtivity_Core.php (modified) (2 diffs)
-
trunk/Logs/Logtivity_Abstract_Logger.php (modified) (1 diff)
-
trunk/logtivity.php (modified) (2 diffs)
-
trunk/readme.md (modified) (2 diffs)
-
trunk/readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
logtivity/trunk/Admin/Logtivity_Log_Index_Controller.php
r2723235 r2813255 23 23 ]) 24 24 ); 25 26 if (!$response) { 27 return $this->errorReponse('Please connect to Logtivity.'); 28 } 25 29 26 30 if (property_exists($response, 'message') && $response->message) { -
logtivity/trunk/Errors/Logtivity_Error_Log.php
r2805342 r2813255 16 16 public function errorHandler( $code, $message, $file = '', $line = 0 ) 17 17 { 18 if (isset($_SERVER['HTTP_HOST'])) { 19 $stack_trace = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS & ~DEBUG_BACKTRACE_PROVIDE_OBJECT); 20 } else { 21 $stack_trace = [ 22 [ 23 'line' => $file, 24 'file' => $line, 25 ] 18 try { 19 if (isset($_SERVER['HTTP_HOST'])) { 20 $stack_trace = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS & ~DEBUG_BACKTRACE_PROVIDE_OBJECT); 21 } else { 22 $stack_trace = [ 23 [ 24 'line' => $file, 25 'file' => $line, 26 ] 27 ]; 28 } 29 30 $error = [ 31 'type' => $code, 32 'message' => $message, 33 'file' => $file, 34 'line' => $line, 35 'stack_trace' => $stack_trace, 36 'level' => 'warning', 26 37 ]; 27 }28 38 29 $error = [ 30 'type' => $code, 31 'message' => $message, 32 'file' => $file, 33 'line' => $line, 34 'stack_trace' => $stack_trace, 35 'level' => 'warning', 36 ]; 39 if ($this->shouldIgnore($error, 'warnings')) { 40 return; 41 } 37 42 38 if ($this->shouldIgnore($error, 'warnings')) {39 return;40 }41 42 try {43 43 Logtivity::logError($error)->send(); 44 } catch (\Throwable $e) { 45 44 46 } catch (\Exception $e) { 45 47 46 48 } 47 49 … … 53 55 public function exceptionHandler(Throwable $throwable) 54 56 { 55 if (isset($_SERVER['HTTP_HOST'])) { 56 $stack_trace = array_merge( 57 [ 57 try { 58 if (isset($_SERVER['HTTP_HOST'])) { 59 $stack_trace = array_merge( 60 [ 61 [ 62 'line' => $throwable->getLine(), 63 'file' => $throwable->getFile(), 64 ] 65 ], 66 $throwable->getTrace(), 67 ); 68 } else { 69 $stack_trace = [ 58 70 [ 59 71 'line' => $throwable->getLine(), 60 72 'file' => $throwable->getFile(), 61 73 ] 62 ], 63 $throwable->getTrace(), 64 ); 65 } else { 66 $stack_trace = [ 67 [ 68 'line' => $throwable->getLine(), 69 'file' => $throwable->getFile(), 70 ] 74 ]; 75 } 76 77 $error = [ 78 'type' => get_class($throwable), 79 'message' => $throwable->getMessage(), 80 'file' => $throwable->getFile(), 81 'line' => $throwable->getLine(), 82 'stack_trace' => $stack_trace, 83 'level' => 'error', 71 84 ]; 85 86 if ($this->shouldIgnore($error, 'errors')) { 87 return; 88 } 89 90 Logtivity::logError($error)->send(); 91 } catch (\Throwable $e) { 92 93 } catch (\Exception $e) { 94 72 95 } 73 74 $error = [75 'type' => get_class($throwable),76 'message' => $throwable->getMessage(),77 'file' => $throwable->getFile(),78 'line' => $throwable->getLine(),79 'stack_trace' => $stack_trace,80 'level' => 'error',81 ];82 83 if ($this->shouldIgnore($error, 'errors')) {84 return;85 }86 87 Logtivity::logError($error)->send();88 96 89 97 if ($this->exceptionHandler) { -
logtivity/trunk/Logs/Core/Logtivity_Core.php
r2805342 r2813255 131 131 'limit_login_retries', 132 132 'post_views_count', 133 'mepr_rules_db_cleanup_last_run', 134 'mepr_products_db_cleanup_last_run', 135 'mepr_coupons_expire_last_run', 136 'mepr_groups_db_cleanup_last_run', 133 137 ]; 134 138 … … 156 160 ->setAction('Option Updated') 157 161 ->setContext($option) 158 ->addMeta ('Old Value', $old_value)159 ->addMeta ('New Value', $value)162 ->addMetaIf(!is_array($old_value) && !is_object($old_value), 'Old Value', $old_value) 163 ->addMetaIf(!is_array($value) && !is_object($value), 'New Value', $value) 160 164 ->send(); 161 165 } -
logtivity/trunk/Logs/Logtivity_Abstract_Logger.php
r2707715 r2813255 77 77 try { 78 78 return new \DateTime( $date ); 79 } catch ( \Exception $e ) { 79 } catch (\Throwable $e) { 80 return new \DateTime( '1970-01-01' ); 81 } catch (\Exception $e) { 80 82 return new \DateTime( '1970-01-01' ); 81 83 } -
logtivity/trunk/logtivity.php
r2805342 r2813255 5 5 * Plugin URI: https://logtivity.io 6 6 * Description: Dedicated Event Monitoring for WordPress using Logtivity.io. 7 * Version: 2.0 7 * Version: 2.0.1 8 8 * Author: Logtivity 9 9 * Text Domain: logtivity … … 12 12 class Logtivity 13 13 { 14 protected $version = '2.0 ';14 protected $version = '2.0.1'; 15 15 16 16 /** -
logtivity/trunk/readme.md
r2805342 r2813255 5 5 Requires at least: 4.7 6 6 Tested up to: 6.0 7 Stable tag: 2.0 7 Stable tag: 2.0.1 8 8 Requires PHP: 7.0 9 9 License: GPLv2 or later … … 226 226 227 227 == Changelog == 228 229 = 2.0.1 = 230 231 _Release Date – Monday 7th November 2022_ 232 233 * Add better messaging on logs page when there are no results. 234 * Refine Option Updated meta sent. 235 * Wrap error logging in try catch just incase of issue during logging. 228 236 229 237 = 2.0 = -
logtivity/trunk/readme.txt
r2805342 r2813255 5 5 Requires at least: 4.7 6 6 Tested up to: 6.0 7 Stable tag: 2.0 7 Stable tag: 2.0.1 8 8 Requires PHP: 7.0 9 9 License: GPLv2 or later … … 226 226 227 227 == Changelog == 228 229 = 2.0.1 = 230 231 _Release Date – Monday 7th November 2022_ 232 233 * Wrap better messaging on logs page when there are no results. 234 * Refine Option Updated meta sent. 235 * Add wrap error logging in try catch just incase of issue during logging. 228 236 229 237 = 2.0 =
Note: See TracChangeset
for help on using the changeset viewer.