84% pure-php-pagination

Code Review | Pure PHP Pagination

WordPress plugin Pure PHP Pagination scored84%from 54 tests.

About plugin

  • Plugin page: pure-php-pagination
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 5.1-5.9
  • WordPress version: 6.3.1
  • First release: Jan 12, 2022
  • Latest release: Jan 23, 2022
  • Number of updates: 4
  • Update frequency: every 3.0 days
  • Top authors: sunukunsinje (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /400 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼5.07ms] Passed 4 tests

A check of server-side resources used by Pure PHP Pagination
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.43 ▼0.0338.81 ▼6.52
Dashboard /wp-admin3.34 ▲0.0445.16 ▼1.01
Posts /wp-admin/edit.php3.39 ▲0.0343.99 ▼7.15
Add New Post /wp-admin/post-new.php5.92 ▲0.0381.75 ▼5.61
Media Library /wp-admin/upload.php3.26 ▲0.0334.58 ▲1.23

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Pure PHP Pagination
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,710 ▼6113.94 ▼0.7111.55 ▲9.4641.06 ▼3.22
Dashboard /wp-admin2,206 ▲215.78 ▼0.08103.65 ▼12.8338.73 ▼6.75
Posts /wp-admin/edit.php2,089 ▼02.04 ▲0.0640.96 ▲1.7938.65 ▲6.66
Add New Post /wp-admin/post-new.php1,546 ▲1322.93 ▼0.33660.82 ▼15.4854.05 ▼3.94
Media Library /wp-admin/upload.php1,388 ▼04.16 ▼0.0694.36 ▼6.6242.19 ▼2.16

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget

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 no errors were found, this is by no means 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
Please take a closer look at the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/pure-php-pagination/pure-php-pagination.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that need to be fixed:
  • Screenshots: These screenshots require images: #1 (The view of the regular pagination.), #2 (The view of the Load More pagination.)
You can look at the official readme.txt

pure-php-pagination/pure-php-pagination.php Passed 13 tests

The entry point to "Pure PHP Pagination" version 1.0.1 is a PHP file that has certain tags in its header comment area
31 characters long description:
Pagination Plugin for WordPress

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 plugin479 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP1308197
JavaScript1290144
CSS110138

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.17
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%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG images were found in this plugin