84% sort-page-list-by-last-name

Code Review | Sort Page List by Last Name

WordPress plugin Sort Page List by Last Name scored84%from 54 tests.

About plugin

  • Plugin page: sort-page-list-by...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.4
  • WordPress version: 6.3.1
  • First release: Dec 4, 2011
  • Latest release: Apr 3, 2020
  • Number of updates: 142
  • Update frequency: every 21.4 days
  • Top authors: studiohyperset (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /2,469 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

A check of server-side resources used by Sort Page List by Last Name
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0147.15 ▼2.23
Dashboard /wp-admin3.32 ▲0.0159.83 ▲1.61
Posts /wp-admin/edit.php3.37 ▲0.0155.55 ▼11.34
Add New Post /wp-admin/post-new.php5.90 ▲0.0199.42 ▼5.10
Media Library /wp-admin/upload.php3.24 ▲0.0141.52 ▲1.79

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Sort Page List by Last Name
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.35 ▼0.351.69 ▼0.0643.88 ▼1.28
Dashboard /wp-admin2,195 ▲185.63 ▼0.0294.21 ▼5.2740.45 ▲0.27
Posts /wp-admin/edit.php2,100 ▼31.99 ▲0.0435.62 ▼8.3933.99 ▼7.98
Add New Post /wp-admin/post-new.php1,535 ▲918.17 ▼4.80659.69 ▲10.4465.76 ▲5.98
Media Library /wp-admin/upload.php1,400 ▼04.25 ▲0.0597.01 ▼15.2341.35 ▼3.73

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
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

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
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_filter() in wp-content/plugins/sort-page-list-by-last-name/sort-page-list-by-last-name.php:35

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
7 plugin tags: name, title, page, wp_list_pages, function...

sort-page-list-by-last-name/sort-page-list-by-last-name.php 92% from 13 tests

Analyzing the main PHP file in "Sort Page List by Last Name" version 1.0
The following require your attention:
  • Description: Please don't use more than 140 characters for the plugin description (currently 732 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin40 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP12925
Markdown113015

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.29
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%
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

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.07MB with 0.07MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
sh-logo.png73.13KB4.09KB▼ 94.41%