84% relevanssi-light

Code Review | Relevanssi Light

WordPress plugin Relevanssi Light scored84%from 54 tests.

About plugin

  • Plugin page: relevanssi-light
  • Plugin version: 1.2.2
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.1
  • WordPress version: 6.3.1
  • First release: Mar 11, 2020
  • Latest release: Dec 9, 2022
  • Number of updates: 11
  • Update frequency: every 91.3 days
  • Top authors: msaari (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

400+ active /10,928 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.01MB] [CPU: ▼10.98ms] Passed 4 tests

An overview of server-side resources used by Relevanssi Light
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0237.29 ▼4.55
Dashboard /wp-admin3.32 ▼0.0243.93 ▼18.67
Posts /wp-admin/edit.php3.38 ▲0.0241.87 ▼0.38
Add New Post /wp-admin/post-new.php5.91 ▲0.0289.02 ▼20.31
Media Library /wp-admin/upload.php3.25 ▲0.0234.89 ▲2.10
Relevanssi Light /wp-admin/options-general.php?page=relevanssi_light3.2229.34

Server storage [IO: ▲0.03MB] [DB: ▲0.07MB] Passed 3 tests

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, 8 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-comments
relevanssi_light_activated
widget_recent-posts
relevanssi_light
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Relevanssi Light
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.34 ▼0.061.71 ▼0.0037.72 ▼5.95
Dashboard /wp-admin2,193 ▲165.55 ▼0.1085.64 ▼11.7241.07 ▼3.64
Posts /wp-admin/edit.php2,104 ▲12.01 ▼0.0034.51 ▼7.8338.99 ▲1.93
Add New Post /wp-admin/post-new.php1,387 ▼13922.02 ▼1.55543.98 ▼107.9061.34 ▲2.37
Media Library /wp-admin/upload.php1,404 ▲14.20 ▼0.0492.26 ▼10.4643.67 ▲0.65
Relevanssi Light /wp-admin/options-general.php?page=relevanssi_light9702.0022.4229.63

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
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 fix the following items
  • 3× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/relevanssi-light/relevanssi-light-admin-ajax.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/relevanssi-light/relevanssi-light-menu.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/relevanssi-light/relevanssi-light-admin-ajax.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
2 plugin tags: fulltext, search

relevanssi-light/relevanssi-light.php 92% from 13 tests

The main file in "Relevanssi Light" v. 1.2.2 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin434 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP479211364
JavaScript15043
CSS15027

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.31
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%
Functions19
▷ Named functions1789.47%
▷ Anonymous functions210.53%
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
There were not PNG files found in your plugin