10% byrev-gallery-pagination-for-wordpress

Code Review | ByREV Gallery Pagination for Wordpress

WordPress plugin ByREV Gallery Pagination for Wordpress scored 10% from 54 tests.

About plugin

  • Plugin page: byrev-gallery-pag...
  • Plugin version: 1.7.3.beta.001...
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.3.2
  • WordPress version: 6.3.1
  • First release: May 16, 2011
  • Latest release: Mar 1, 2013
  • Number of updates: 32
  • Update frequency: every 20.4 days
  • Top authors: byrev (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

50+ active / 13,715 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
These installer errors require your attention
  • Install procedure validation failed for this plugin
    • > Notice in wp-content/plugins/byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php+262
    Undefined variable: addr

Server metrics [RAM: ▼1.96MB] [CPU: ▼52.19ms] Passed 4 tests

An overview of server-side resources used by ByREV Gallery Pagination for Wordpress
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.434.77 ▼34.79
Dashboard /wp-admin2.05 ▼1.266.65 ▼44.01
Posts /wp-admin/edit.php2.05 ▼1.317.07 ▼41.84
Add New Post /wp-admin/post-new.php2.05 ▼3.846.30 ▼88.11
Media Library /wp-admin/upload.php2.05 ▼1.185.83 ▼30.90
Gallery Pagination /wp-admin/options-general.php?page=byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php2.056.92

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for ByREV Gallery Pagination for Wordpress
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,881 ▲14613.50 ▼0.905.15 ▲3.4536.11 ▼8.39
Dashboard /wp-admin2,210 ▲194.89 ▼0.01111.90 ▲9.4144.66 ▼0.88
Posts /wp-admin/edit.php2,090 ▲42.01 ▲0.0134.46 ▼1.4734.57 ▲1.18
Add New Post /wp-admin/post-new.php1,536 ▼123.43 ▲0.45668.10 ▼28.3961.15 ▼0.32
Media Library /wp-admin/upload.php1,395 ▲44.17 ▼0.0695.00 ▼6.9542.20 ▼1.80
Gallery Pagination /wp-admin/options-general.php?page=byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php1,2102.0723.2652.85

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • Uninstall procedure had uncaught errors
    • > Notice in wp-content/plugins/byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php+262
    Undefined variable: addr
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php
    • > Notice in wp-content/plugins/byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php+262
    Undefined variable: addr
    • > GET request to /wp-admin/options-general.php?page=byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php
    • > Notice in wp-content/plugins/byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php+262
    Trying to access array offset on value of type null
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.

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 fix the following items
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/byrev-gallery-pagination-for-wordpress/cleanfolder.php
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php:74

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 errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
7 plugin tags: images, pagination, pictures, gallery, photography...

byrev-gallery-pagination-for-wordpress/byrev-gallery-pagination.php 77% from 13 tests

"ByREV Gallery Pagination for Wordpress" version 1.7.3.beta.001...'s primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Description: Please don't use more than 140 characters for the plugin description (currently 440 characters long)
  • Version: Plugin version number should only contain digits separated by dots (ex. "1.0.3" instead of "1.7.3.beta.001...")
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("byrev-gallery-pagination-for-wordpress.php" instead of "byrev-gallery-pagination.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
No dangerous file extensions were detected995 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP7207105991
CSS1004

PHP code Passed 2 tests

Analyzing 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.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%
Functions37
▷ Named functions37100.00%
▷ Anonymous functions00.00%
Constants78
▷ Global constants78100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
5 PNG files occupy 0.47MB with 0.21MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-3.png274.56KB99.19KB▼ 63.87%
screenshot-2.png179.18KB68.02KB▼ 62.04%
noimage.png6.17KB4.81KB▼ 22.05%
noimage2.png0.49KB0.31KB▼ 36.24%
screenshot-1.png17.84KB10.39KB▼ 41.77%