83% theme-plugin-profiler

Code Review | Theme and Plugin (T&P) Profiler

WordPress plugin Theme and Plugin (T&P) Profiler scored 83% from 54 tests.

About plugin

  • Plugin page: theme-plugin-prof...
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.4.2
  • WordPress version: 6.3.1
  • First release: Apr 7, 2016
  • Latest release: Apr 11, 2016
  • Number of updates: 16
  • Update frequency: every 0.3 days
  • Top authors: cjbj (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,026 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

Analyzing server-side resources used by Theme and Plugin (T&P) Profiler
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0440.85 ▲0.33
Dashboard /wp-admin3.35 ▲0.0549.21 ▲0.78
Posts /wp-admin/edit.php3.40 ▲0.0444.39 ▼0.19
Add New Post /wp-admin/post-new.php5.93 ▲0.0494.90 ▼0.18
Media Library /wp-admin/upload.php3.27 ▲0.0436.54 ▲0.81
T&P Profiler /wp-admin/tools.php?page=thplpr3.2432.77

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Theme and Plugin (T&P) Profiler
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲6913.27 ▼1.114.87 ▲2.7947.02 ▲6.63
Dashboard /wp-admin2,213 ▲244.83 ▼0.0794.36 ▼18.4338.26 ▼6.09
Posts /wp-admin/edit.php2,090 ▲12.01 ▲0.0236.58 ▼2.1434.45 ▲0.19
Add New Post /wp-admin/post-new.php1,536 ▲1523.52 ▲0.35631.22 ▼59.3758.16 ▲1.25
Media Library /wp-admin/upload.php1,392 ▲14.18 ▼0.06108.05 ▲0.1047.13 ▲3.83
T&P Profiler /wp-admin/tools.php?page=thplpr8662.0522.1029.12

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/theme-plugin-profiler/thplpr.php:22

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Please fix the following attributes:
  • Screenshots: Please add images for these screenshots: #1 (Options page), #2 (Sample output)
  • Plugin Name: Please specify the plugin name on the first line ( === theme-plugin-profiler === )
The official readme.txt might help

theme-plugin-profiler/thplpr.php 85% from 13 tests

"Theme and Plugin (T&P) Profiler" version 0.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("theme-plugin-profiler.php" instead of "thplpr.php")
  • Description: Keep the plugin description shorter than 140 characters (currently 163 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin153 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP14730153

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.19
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions13
▷ Named functions13100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected