78% infinite-related-next-post-manager

Code Review | Infinite Related Next Post Manager for WordPress

WordPress plugin Infinite Related Next Post Manager for WordPress scored 78% from 54 tests.

About plugin

  • Plugin page: infinite-related-...
  • Plugin version: 1.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1-5.1
  • WordPress version: 6.3.1
  • First release: Mar 12, 2019
  • Latest release: Mar 15, 2019
  • Number of updates: 4
  • Update frequency: every 1.3 days
  • Top authors: saragna (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,106 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.00MB] [CPU: ▼3.86ms] Passed 4 tests

Analyzing server-side resources used by Infinite Related Next Post Manager for WordPress
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.40 ▼0.0635.24 ▼6.37
Dashboard /wp-admin3.32 ▲0.0248.37 ▲0.97
Posts /wp-admin/edit.php3.38 ▲0.0244.91 ▼6.58
Add New Post /wp-admin/post-new.php5.93 ▲0.0486.29 ▼2.65
Media Library /wp-admin/upload.php3.24 ▲0.0236.50 ▲0.16

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 24 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
can_compress_scripts
db_upgraded
_winpm_next_post_option
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Infinite Related Next Post Manager for WordPress
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,947 ▲21215.18 ▲0.897.14 ▲5.3441.81 ▼9.02
Dashboard /wp-admin2,262 ▲746.24 ▲1.17125.31 ▲18.9282.58 ▲33.98
Posts /wp-admin/edit.php2,147 ▲583.06 ▲1.0040.38 ▲1.0253.33 ▲17.56
Add New Post /wp-admin/post-new.php6,617 ▲5,08421.40 ▼1.73902.43 ▲219.5162.38 ▲11.65
Media Library /wp-admin/upload.php1,500 ▲1095.46 ▲1.28116.71 ▲14.8844.31 ▼2.69

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 7 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • _winpm_next_post_option
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts

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 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/infinite-related-next-post-manager/admin/grid-setting.php
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function admin_url() in wp-content/plugins/infinite-related-next-post-manager/admin/setting.php:19
    • > PHP Fatal error
      Uncaught Error: Cannot access self:: when no class scope is active in wp-content/plugins/infinite-related-next-post-manager/admin/grid-setting.php:197

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: related post, infinite scroll, post manager, sidebar, next post

infinite-related-next-post-manager/wp-next-post-manager.php 85% from 13 tests

"Infinite Related Next Post Manager for WordPress" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("infinite-related-next-post-manager.php" instead of "wp-next-post-manager.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected3,195 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP788711,519
CSS334131,353
SVG100212
JavaScript5156111

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.16
Average class complexity7.50
▷ Minimum class complexity1.00
▷ Maximum class complexity25.00
Average method complexity2.53
▷ Minimum method complexity1.00
▷ Maximum method complexity22.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods17
▷ Static methods211.76%
▷ Public methods1482.35%
▷ Protected methods317.65%
▷ Private methods00.00%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
3 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/image/icon.png3.37KB0.78KB▼ 76.88%
assets/image/line.png0.08KB0.10KB0.00%
assets/image/round.png4.19KB1.43KB▼ 65.87%