78% related-links-inside-content

Code Review | Related Links Inside Content

WordPress plugin Related Links Inside Content scored78%from 54 tests.

About plugin

  • Plugin page: related-links-ins...
  • Plugin version: 1.01
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-4.9.4
  • WordPress version: 6.3.1
  • First release: Mar 9, 2018
  • Latest release: Mar 19, 2018
  • Number of updates: 8
  • Update frequency: every 1.3 days
  • Top authors: trqnwr (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /528 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼11.83ms] Passed 4 tests

A check of server-side resources used by Related Links Inside Content
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0133.80 ▼1.16
Dashboard /wp-admin3.32 ▼0.0342.20 ▼17.81
Posts /wp-admin/edit.php3.37 ▲0.0148.35 ▲3.74
Add New Post /wp-admin/post-new.php5.92 ▲0.0477.43 ▼27.54
Media Library /wp-admin/upload.php3.24 ▲0.0132.45 ▼0.81
RLIC Settings /wp-admin/options-general.php?page=rlic-settings3.2124.91

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Related Links Inside Content
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲7914.37 ▲0.021.69 ▼0.0336.66 ▼3.57
Dashboard /wp-admin2,205 ▲285.60 ▲0.0694.97 ▲10.3043.08 ▲2.90
Posts /wp-admin/edit.php2,113 ▲102.01 ▲0.0738.26 ▲1.2834.29 ▼1.22
Add New Post /wp-admin/post-new.php6,280 ▲4,75226.24 ▲3.05933.52 ▲331.1855.08 ▲3.32
Media Library /wp-admin/upload.php1,410 ▲104.11 ▼0.10107.33 ▲8.1041.46 ▼3.43
RLIC Settings /wp-admin/options-general.php?page=rlic-settings7972.0426.5826.20

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
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Almost there! Just fix the following items
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/related-links-inside-content/rlic.php
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/related-links-inside-content/setting_page.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/related-links-inside-content/add_custom_field.php:37

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)
Everything seems fine on the user side

Optimizations

Plugin configuration 93% 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
These attributes need your attention:
  • Donate link: Invalid URI found ("paypal.me/trqnwr")
Please take inspiration from this readme.txt

related-links-inside-content/rlic.php 92% from 13 tests

The main PHP script in "Related Links Inside Content" version 1.01 is automatically included on every request by WordPress
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("related-links-inside-content.php" instead of "rlic.php")

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
Good job! No executable or dangerous file extensions detected323 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP418272194
JavaScript117062
Markdown122034
CSS13033

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
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%
Functions14
▷ Named functions14100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
3 PNG files occupy 0.06MB with 0.02MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshots/screenshot-three.png14.92KB8.87KB▼ 40.56%
screenshots/screenshot-one.png26.67KB13.88KB▼ 47.95%
screenshots/screenshot-two.png16.83KB10.05KB▼ 40.30%