78% fancy-results-page-for-listhub

Code Review | Fancy Results - Listhub for WordPress

WordPress plugin Fancy Results - Listhub for WordPress scored78%from 54 tests.

About plugin

  • Plugin page: fancy-results-pag...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.7
  • WordPress version: 6.3.1
  • First release: Mar 18, 2017
  • Latest release: Mar 29, 2017
  • Number of updates: 7
  • Update frequency: every 1.0 days
  • Top authors: RealtyCandy (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /482 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

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

An overview of server-side resources used by Fancy Results - Listhub for WordPress
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0141.02 ▼3.46
Dashboard /wp-admin3.32 ▲0.0149.25 ▼3.39
Posts /wp-admin/edit.php3.37 ▲0.0148.06 ▼1.83
Add New Post /wp-admin/post-new.php5.90 ▲0.0191.21 ▼5.92
Media Library /wp-admin/upload.php3.24 ▲0.0137.70 ▼0.14

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Fancy Results - Listhub for WordPress
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,874 ▲11313.41 ▼0.949.46 ▲7.6542.99 ▲2.56
Dashboard /wp-admin2,198 ▲185.60 ▼0.0592.17 ▼1.6840.05 ▼2.93
Posts /wp-admin/edit.php2,079 ▼211.99 ▼0.0236.22 ▼0.2832.64 ▼8.60
Add New Post /wp-admin/post-new.php1,534 ▲818.14 ▼4.67632.69 ▼23.7871.60 ▲15.26
Media Library /wp-admin/upload.php1,400 ▲34.21 ▼0.10102.31 ▼5.0345.07 ▲2.81

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
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
  • 2× PHP files output text when accessed directly:
    • > /wp-content/plugins/fancy-results-page-for-listhub/class-modern-layout.php
    • > /wp-content/plugins/fancy-results-page-for-listhub/plugin.php
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to a member function get() on null in wp-content/plugins/fancy-results-page-for-listhub/tmpl/pagination.php:3
    • > PHP Fatal error
      Uncaught Error: Call to a member function get() on null in wp-content/plugins/fancy-results-page-for-listhub/tmpl/fancy_layout.php:7

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Tags: You are using too many tags: 12 tag instead of maximum 10
The official readme.txt is a good inspiration

fancy-results-page-for-listhub/plugin.php 92% from 13 tests

The main PHP script in "Fancy Results - Listhub for WordPress" version 1.0.0 is automatically included on every request by WordPress
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("fancy-results-page-for-listhub.php" instead of "plugin.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
There were no executable files found in this plugin131 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP42114129
CSS1001
JavaScript1001

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods3100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
PNG images were not found in this plugin