84% tdd-debug-bar-post-meta

Code Review | Debug Bar Post Meta

WordPress plugin Debug Bar Post Meta scored84%from 54 tests.

About plugin

  • Plugin page: tdd-debug-bar-pos...
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.4.2-3.4.2
  • WordPress version: 6.3.1
  • First release: Sep 19, 2012
  • Latest release: Sep 19, 2012
  • Number of updates: 6
  • Update frequency: N/A
  • Top authors: taylorde (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

20+ active /4,902 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼4.10ms] Passed 4 tests

An overview of server-side resources used by Debug Bar Post Meta
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0042.45 ▼1.59
Dashboard /wp-admin3.31 ▲0.0148.14 ▼5.62
Posts /wp-admin/edit.php3.36 ▲0.0050.08 ▲2.93
Add New Post /wp-admin/post-new.php5.89 ▲0.0084.69 ▼12.11
Media Library /wp-admin/upload.php3.23 ▲0.0038.52 ▲5.04

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

Debug Bar Post Meta: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.69 ▼0.944.63 ▲2.6243.86 ▼2.26
Dashboard /wp-admin2,206 ▲214.86 ▼0.18110.56 ▼0.6140.61 ▼5.08
Posts /wp-admin/edit.php2,089 ▼02.01 ▼0.0040.34 ▲0.8534.15 ▼3.22
Add New Post /wp-admin/post-new.php1,533 ▲517.63 ▼5.68676.61 ▲36.3455.68 ▲3.34
Media Library /wp-admin/upload.php1,385 ▼04.20 ▲0.03104.10 ▼5.3042.65 ▼3.36

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

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
Almost there! Just fix the following items
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Class 'Debug_Bar_Panel' not found in wp-content/plugins/tdd-debug-bar-post-meta/class-debug-bar-post-meta.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/tdd-debug-bar-post-meta/debug-bar-post-meta.php:26

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
4 plugin tags: debug bar, post meta, meta, custom fields

tdd-debug-bar-post-meta/debug-bar-post-meta.php 92% from 13 tests

The principal PHP file in "Debug Bar Post Meta" v. 0.1 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("tdd-debug-bar-post-meta.php" instead of "debug-bar-post-meta.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin80 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP291663
CSS23017

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity9.00
▷ Minimum class complexity9.00
▷ Maximum class complexity9.00
Average method complexity2.60
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods00.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There were not PNG files found in your plugin