84% super-simple-related-posts

Code Review | Super Simple Related Posts

WordPress plugin Super Simple Related Posts scored 84% from 54 tests.

About plugin

  • Plugin page: super-simple-rela...
  • Plugin version: 1.5.4
  • PHP version: 7.4.16
  • WordPress compatibility: 5.4-5.7.2
  • WordPress version: 5.9.2
  • First release: Sep 21, 2013
  • Latest release: Jun 21, 2021
  • Number of updates: 40
  • Update frequency: every 71.5 days
  • Top authors: McGuive7 (80%)aaronbmm (22.5%)

Code review

54 tests

User reviews

12 reviews

Install metrics

100+ active / 9,530 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
Installer ran successfully

Server metrics [RAM: ▲0.06MB] [CPU: ▼308.99ms] Passed 4 tests

Server-side resources used by Super Simple Related Posts
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.60 ▲0.0954.83 ▼4.35
Dashboard /wp-admin3.49 ▲0.0835.71 ▼1.12
Posts /wp-admin/edit.php3.72 ▲0.0942.95 ▲6.01
Add New Post /wp-admin/post-new.php6.96 ▼0.0195.58 ▼1,225.06
Media Library /wp-admin/upload.php3.37 ▲0.0825.32 ▼5.43

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 5 new files
Database: no new tables, 1 new option
New WordPress options
widget_ssrp

Browser metrics Passed 4 tests

A check of browser resources used by Super Simple Related Posts
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,749 ▼915.12 ▼0.505.66 ▼0.262.46 ▼0.03
Dashboard /wp-admin2,881 ▲276.09 ▼0.06128.09 ▼12.42166.47 ▼1.39
Posts /wp-admin/edit.php2,694 ▲33.22 ▼0.0164.87 ▲0.83145.20 ▼45.11
Add New Post /wp-admin/post-new.php1,690 ▲2921.53 ▲4.72447.40 ▲5.88161.29 ▼15.60
Media Library /wp-admin/upload.php1,698 ▼05.52 ▼0.02151.54 ▲9.60194.09 ▲6.36

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 were found after uninstall: 1 option
    • widget_ssrp

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% 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 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 _e() in wp-content/plugins/super-simple-related-posts/super-simple-related-posts.php:28

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
7 plugin tags: taxonomy, related, tag, posts, content...

super-simple-related-posts/super-simple-related-posts.php Passed 13 tests

Analyzing the main PHP file in "Super Simple Related Posts" version 1.5.4
94 characters long description:
A super simple plugin to output related posts based on categories, tags, or custom taxonomies.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin306 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP197167291
PO File10015

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity41.00
▷ Minimum class complexity41.00
▷ Maximum class complexity41.00
Average method complexity9.00
▷ Minimum method complexity1.00
▷ Maximum method complexity32.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods00.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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
There were not PNG files found in your plugin