79% wp-reporter

Code Review | WP Reporter

WordPress plugin WP Reporter scored79%from 54 tests.

About plugin

  • Plugin page: wp-reporter
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5.0-4.9.4
  • WordPress version: 6.3.1
  • First release: Feb 4, 2018
  • Latest release: Feb 9, 2018
  • Number of updates: 7
  • Update frequency: every 0.7 days
  • Top authors: pbimal (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /489 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.01MB] [CPU: ▼2.33ms] Passed 4 tests

This is a short check of server-side resources used by WP Reporter
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0137.82 ▼2.73
Dashboard /wp-admin3.31 ▲0.0148.21 ▼5.81
Posts /wp-admin/edit.php3.36 ▲0.0153.90 ▲3.95
Add New Post /wp-admin/post-new.php5.89 ▲0.0194.45 ▲3.54
Media Library /wp-admin/upload.php3.24 ▲0.0136.48 ▼4.32

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 13 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for WP Reporter
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,841 ▲7013.71 ▼0.692.03 ▼0.2639.28 ▼4.73
Dashboard /wp-admin2,222 ▲345.90 ▲0.04105.89 ▼1.8242.83 ▲0.46
Posts /wp-admin/edit.php2,102 ▲132.02 ▲0.0340.83 ▲4.5635.10 ▲0.88
Add New Post /wp-admin/post-new.php1,560 ▲2518.72 ▼4.36629.95 ▼61.9352.69 ▲1.62
Media Library /wp-admin/upload.php1,398 ▲134.21 ▼0.01100.87 ▼0.2944.62 ▼2.94

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% 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
  • 6× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/wp-reporter/includes/pages.php
    • > /wp-content/plugins/wp-reporter/includes/tags.php
    • > /wp-content/plugins/wp-reporter/includes/users.php
    • > /wp-content/plugins/wp-reporter/includes/comments.php
    • > /wp-content/plugins/wp-reporter/includes/posts.php
    • > /wp-content/plugins/wp-reporter/includes/categories.php
  • 63× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Notice
      Undefined variable: comments_count in wp-content/plugins/wp-reporter/includes/comments.php on line 15
    • > PHP Notice
      Trying to get property 'future' of non-object in wp-content/plugins/wp-reporter/includes/pages.php on line 18
    • > PHP Notice
      Undefined variable: total_posts in wp-content/plugins/wp-reporter/includes/posts.php on line 1
    • > PHP Notice
      Undefined variable: comments_count in wp-content/plugins/wp-reporter/includes/comments.php on line 1
    • > PHP Notice
      Trying to get property 'future' of non-object in wp-content/plugins/wp-reporter/includes/posts.php on line 18
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/wp-reporter/includes/users.php on line 14
    • > PHP Notice
      Undefined variable: count_posts in wp-content/plugins/wp-reporter/includes/posts.php on line 22
    • > PHP Notice
      Undefined variable: total_pages in wp-content/plugins/wp-reporter/includes/pages.php on line 1
    • > PHP Notice
      Undefined variable: comments_count in wp-content/plugins/wp-reporter/includes/comments.php on line 18
    • > PHP Notice
      Trying to get property 'auto-draft' of non-object in wp-content/plugins/wp-reporter/includes/posts.php on line 23

User-side errors Passed 1 test

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

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
3 plugin tags: counter, posts count, reporter

wp-reporter/wp-reporter.php Passed 13 tests

The main PHP file in "WP Reporter" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
83 characters long description:
Counts and reports WordPress resources - Posts, Pages, Comments, Users, Categories.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin198 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP81936198

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.09
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%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There are no PNG files in this plugin