78% sopro

Code Review | Sopro

WordPress plugin Sopro scored 78% from 54 tests.

About plugin

  • Plugin page: sopro
  • Plugin version: 1.0.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0.1-6.3
  • WordPress version: 6.3.1
  • First release: May 31, 2021
  • Latest release: Sep 11, 2023
  • Number of updates: 18
  • Update frequency: every 46.9 days
  • Top authors: vladimirsopro (100%)

Code review

54 tests

User reviews

1 review

Install metrics

400+ active / 1,534 total downloads


Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.07MB] [CPU: ▼3.12ms] Passed 4 tests

Analyzing server-side resources used by Sopro
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0735.49 ▼5.90
Dashboard /wp-admin3.37 ▲0.0744.18 ▼2.59
Posts /wp-admin/edit.php3.49 ▲0.1346.51 ▼3.42
Add New Post /wp-admin/post-new.php5.97 ▲0.0997.15 ▲6.78
Media Library /wp-admin/upload.php3.30 ▲0.0734.89 ▼0.55
Sopro Plugin /wp-admin/options-general.php?page=sopro3.2632.02

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 23 new files
Database: no new tables, 6 new options
New WordPress options

Browser metrics Passed 4 tests

Checking browser requirements for Sopro
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,916 ▲18113.62 ▼1.145.03 ▲3.3844.63 ▲2.51
Dashboard /wp-admin2,211 ▲405.83 ▲0.9095.20 ▼21.6639.01 ▼5.99
Posts /wp-admin/edit.php2,097 ▲52.00 ▼0.0436.90 ▼3.9931.89 ▼1.66
Add New Post /wp-admin/post-new.php1,530 ▼318.10 ▼5.00620.24 ▼35.0353.19 ▼4.94
Media Library /wp-admin/upload.php1,393 ▲84.24 ▼0.1696.71 ▼5.1541.33 ▼6.73
Sopro Plugin /wp-admin/options-general.php?page=sopro8412.0123.5627.10

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/sopro/public/partials/sopro-plugin-public-display.php
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/sopro/admin/partials/sopro-plugin-admin-display.php:18

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test


Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
3 plugin tags: analytics, sopro, tracking

sopro/sopro-plugin.php 92% from 13 tests

This is the main PHP file of "Sopro" version 1.0.3, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("sopro.php" instead of "sopro-plugin.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
Success! There were no dangerous files found in this plugin277 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.09
Average class complexity2.00
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.23
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
▷ Static methods26.67%
▷ Public methods2583.33%
▷ Protected methods00.00%
▷ Private methods516.67%
▷ Named functions3100.00%
▷ Anonymous functions00.00%
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG files were detected