68% wp-track-keeper

Code Review | WP Track Kepper

WordPress plugin WP Track Kepper scored68%from 54 tests.

About plugin

  • Plugin page: wp-track-keeper
  • Plugin version: 1.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-5.2.3
  • WordPress version: 6.3.1
  • First release: Oct 3, 2019
  • Latest release: Oct 3, 2019
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: De paragon (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /525 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.18MB] [CPU: ▼7.43ms] Passed 4 tests

Server-side resources used by WP Track Kepper
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1543.45 ▼1.85
Dashboard /wp-admin3.49 ▲0.1955.47 ▼12.07
Posts /wp-admin/edit.php3.61 ▲0.2545.26 ▼5.22
Add New Post /wp-admin/post-new.php6.07 ▲0.1987.49 ▼10.57
Media Library /wp-admin/upload.php3.41 ▲0.1940.58 ▲1.54
Manage Tracked Files /wp-admin/admin.php?page=tk_military_action3.1525.98

Server storage [IO: ▲1.05MB] [DB: ▲0.00MB] Passed 3 tests

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 49 new files
Database: 1 new table, 23 new options
New tables
wp_trackedfiles_reference_state
New WordPress options
tk_cron_set_smtp_password
tk_cron_set_sms_sender
tk_cron_set_mail_email
theysaidso_admin_options
tk_cron_set_enable
widget_theysaidso_widget
tk_cron_set_smtp_user
tk_cron_set_sendsms
tk_cron_set_smtp
tk_cron_set_sendmail
...

Browser metrics Passed 4 tests

Checking browser requirements for WP Track Kepper
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,820 ▲5914.35 ▼0.001.86 ▲0.0235.44 ▼10.66
Dashboard /wp-admin2,223 ▲435.58 ▼0.1087.71 ▼9.4844.83 ▲2.87
Posts /wp-admin/edit.php2,131 ▲342.00 ▼0.1036.44 ▼1.6639.01 ▲0.87
Add New Post /wp-admin/post-new.php1,555 ▲2823.20 ▼0.04678.08 ▲12.9363.83 ▲10.93
Media Library /wp-admin/upload.php1,425 ▲224.20 ▼0.02105.50 ▲1.4349.81 ▲2.72
Manage Tracked Files /wp-admin/admin.php?page=tk_military_action280.420.085.25

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • The uninstall procedure failed, leaving 1 table in the database
    • wp_trackedfiles_reference_state
  • This plugin does not fully uninstall, leaving 23 options in the database
    • tk_cron_set_sms_username
    • widget_recent-posts
    • wpTrackKeeperScheduleTime
    • tk_cron_set_mix_name_file
    • db_upgraded
    • tk_cron_set_sms_sender
    • widget_theysaidso_widget
    • tk_cron_set_smtp_host
    • tk_cron_set_delete
    • widget_recent-comments
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Almost there! Just fix the following items
  • 4× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-track-keeper/core/TKScheduler.php:10
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-track-keeper/classes/TKMailBoss.php on line 7
    • > PHP Warning
      require_once(ABSPATHwp-includes/class-phpmailer.php): failed to open stream: No such file or directory in wp-content/plugins/wp-track-keeper/classes/TKMailBoss.php on line 7
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-includes/class-phpmailer.php' (include_path='.:/usr/share/php') in wp-content/plugins/wp-track-keeper/classes/TKMailBoss.php on line 7

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Please fix the following browser errors
    • > GET request to /wp-admin/admin.php?page=tk_military_action
    • > Network (severe)
    wp-admin/admin.php?page=tk_military_action - Failed to load resource: the server responded with a status of 403 (Forbidden)

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Donate link: Invalid URI ("3HPrLAAqc4fYiuKeviD61JKRGhHmpVKixB")
The official readme.txt is a good inspiration

wp-track-keeper/wp-track-keeper.php Passed 13 tests

The entry point to "WP Track Kepper" version 1.0 is a PHP file that has certain tags in its header comment area
88 characters long description:
Keeps track of your wordpress files and sends instant notification when any file changes

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
There were no executable files found in this plugin2,811 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
PHP14511571,452
SVG100685
HTML18062338
CSS45219286
Markdown128045
JSON1005

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity13.42
▷ Minimum class complexity1.00
▷ Maximum class complexity44.00
Average method complexity3.13
▷ Minimum method complexity1.00
▷ Maximum method complexity28.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes12
▷ Abstract classes00.00%
▷ Concrete classes12100.00%
▷ Final classes00.00%
Methods70
▷ Static methods710.00%
▷ Public methods70100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants00.00%
▷ Class constants3100.00%
▷ Public constants3100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
mail/img/arr_icon.png1.14KB0.40KB▼ 65.07%