89% woo-serveloja

Code Review | WooCommerce Serveloja

WordPress plugin WooCommerce Serveloja scored89%from 54 tests.

About plugin

  • Plugin page: woo-serveloja
  • Plugin version: 2.6.2
  • PHP version: 7.4.16
  • WordPress compatibility: 5.5-5.7.2
  • WordPress version: 6.3.1
  • First release: Apr 17, 2018
  • Latest release: May 20, 2021
  • Number of updates: 45
  • Update frequency: every 27.0 days
  • Top authors: serveloja (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /815 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.02MB] [CPU: ▼3.01ms] Passed 4 tests

Analyzing server-side resources used by WooCommerce Serveloja
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0237.42 ▼5.99
Dashboard /wp-admin3.32 ▲0.0244.62 ▼6.19
Posts /wp-admin/edit.php3.37 ▲0.0248.45 ▲3.14
Add New Post /wp-admin/post-new.php5.90 ▲0.0281.80 ▼2.17
Media Library /wp-admin/upload.php3.25 ▲0.0234.79 ▲2.32

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 72 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for WooCommerce Serveloja
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲2914.48 ▲0.211.68 ▼0.2840.41 ▼3.23
Dashboard /wp-admin2,206 ▲184.77 ▼1.2897.65 ▼18.8243.46 ▼2.03
Posts /wp-admin/edit.php2,089 ▼02.01 ▲0.0136.09 ▼3.1834.26 ▲1.40
Add New Post /wp-admin/post-new.php1,514 ▼1417.69 ▼0.63650.11 ▲41.9750.52 ▲1.01
Media Library /wp-admin/upload.php1,388 ▼04.26 ▲0.0895.40 ▼4.9242.01 ▼0.97

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP Passed 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
No output text or server-side errors detected on direct access of PHP files

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 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need your attention:
  • Screenshots: These screenshots lack descriptions #1, #10, #11, #12, #2, #3, #4, #5, #6, #7, #8, #9 in woo-serveloja/assets to your readme.txt
  • Donate link: Invalid URI ("")
You can take inspiration from this readme.txt

woo-serveloja/woocommerce-serveloja.php 92% from 13 tests

This is the main PHP file of "WooCommerce Serveloja" version 2.6.2, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("woo-serveloja.php" instead of "woocommerce-serveloja.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin4,325 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP103532222,258
CSS4295601,817
JavaScript22513250

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity15.50
▷ Minimum class complexity1.00
▷ Maximum class complexity46.00
Average method complexity2.53
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods58
▷ Static methods2441.38%
▷ Public methods2746.55%
▷ Protected methods00.00%
▷ Private methods3153.45%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants150.00%
▷ Class constants150.00%
▷ Public constants1100.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
52 PNG files occupy 0.39MB with 0.18MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/Bandeiras antigas/amex.png9.02KB3.71KB▼ 58.82%
assets/images/bgModal.png46.69KB0.10KB▼ 99.78%
assets/images/logo-checkout.png5.59KB2.80KB▼ 49.87%
assets/images/hiper.png1.25KB1.22KB▼ 2.43%
assets/images/home.png3.52KB2.65KB▼ 24.80%