84% martinus-partnersky-system

Code Review | Partnerský systém Martinus

WordPress plugin Partnerský systém Martinus scored84%from 54 tests.

About plugin

  • Plugin page: martinus-partners...
  • Plugin version: 1.7.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.1.0
  • WordPress version: 6.3.1
  • First release: Apr 19, 2014
  • Latest release: Mar 7, 2019
  • Number of updates: 45
  • Update frequency: every 39.6 days
  • Top authors: maxomatos (62.22%).dan (40%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /1,564 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

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

An overview of server-side resources used by Partnerský systém Martinus
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0740.55 ▲2.07
Dashboard /wp-admin3.36 ▲0.0645.74 ▼1.08
Posts /wp-admin/edit.php3.41 ▲0.0648.54 ▲0.33
Add New Post /wp-admin/post-new.php7.22 ▲1.34108.39 ▲17.15
Media Library /wp-admin/upload.php3.29 ▲0.0634.21 ▲2.64
Martinus PP /wp-admin/options-general.php?page=martinus_pp3.2530.66

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 11 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_martinus-pp
widget_theysaidso_widget
widget_recent-posts
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by Partnerský systém Martinus
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,844 ▲10913.29 ▼1.083.09 ▲1.4644.82 ▲7.10
Dashboard /wp-admin2,207 ▲215.77 ▲0.64105.16 ▼2.5140.58 ▼0.56
Posts /wp-admin/edit.php2,093 ▲42.00 ▼0.0640.02 ▲4.6835.35 ▲1.97
Add New Post /wp-admin/post-new.php6,253 ▲4,73420.72 ▼2.38933.33 ▲260.8738.07 ▼17.06
Media Library /wp-admin/upload.php1,392 ▲14.23 ▲0.04106.25 ▲9.4344.99 ▼2.91
Martinus PP /wp-admin/options-general.php?page=martinus_pp7992.0628.9225.99

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 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
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_recent-posts
    • widget_martinus-pp
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% 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× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/martinus-partnersky-system/martinus-pp.php:30

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

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
1 plugin tags: martinus

martinus-partnersky-system/martinus-pp.php 92% from 13 tests

The entry point to "Partnerský systém Martinus" version 1.7.1 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("martinus-partnersky-system.php" instead of "martinus-pp.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected9,851 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
JSON2009,499
JavaScript52250320
CSS16531
PHP1001

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity21.00
▷ Minimum class complexity21.00
▷ Maximum class complexity21.00
Average method complexity6.00
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
js/martinus-16x16.png3.29KB0.71KB▼ 78.48%