78% bulk-products-selling

Code Review | Bulk Product Selling

WordPress plugin Bulk Product Selling scored 78% from 54 tests.

About plugin

  • Plugin page: bulk-products-sel...
  • Plugin version: 1.0.2
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.0
  • WordPress version: 6.3.1
  • First release: Jun 24, 2021
  • Latest release: Jun 13, 2022
  • Number of updates: 6
  • Update frequency: every 59.2 days
  • Top authors: ok9xnirab (50%)istiaqnirab (50%)springdevs (33.33%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 374 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

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

Analyzing server-side resources used by Bulk Product Selling
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0737.93 ▼3.37
Dashboard /wp-admin3.37 ▲0.0745.93 ▼2.09
Posts /wp-admin/edit.php3.49 ▲0.1348.98 ▲2.80
Add New Post /wp-admin/post-new.php5.95 ▲0.0796.68 ▼1.77
Media Library /wp-admin/upload.php3.30 ▲0.0734.34 ▲0.17

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 34 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
db_upgraded
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Bulk Product Selling
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,823 ▲8813.23 ▼1.185.06 ▲3.1942.17 ▼5.04
Dashboard /wp-admin2,229 ▲445.80 ▼0.0297.51 ▼2.4741.54 ▼6.95
Posts /wp-admin/edit.php2,114 ▲252.07 ▲0.0239.91 ▲0.5939.90 ▲5.81
Add New Post /wp-admin/post-new.php1,560 ▲2718.21 ▼5.26627.46 ▼39.9757.26 ▼4.59
Media Library /wp-admin/upload.php1,414 ▲234.21 ▲0.0194.31 ▼4.4343.60 ▲0.19

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
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
The following issues need your attention
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/bulk-products-selling/includes/Admin/views/footer-script.php
  • 5× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to a member function get_items() on null in wp-content/plugins/bulk-products-selling/includes/Frontend/views/included-products.php:4
    • > PHP Notice
      Undefined variable: is_bulk in wp-content/plugins/bulk-products-selling/includes/Admin/views/footer-script.php on line 9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/bulk-products-selling/includes/Admin/views/plugin-notice.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/bulk-products-selling/includes/Admin/views/tab-content.php:4
    • > PHP Notice
      Undefined variable: order in wp-content/plugins/bulk-products-selling/includes/Frontend/views/included-products.php on line 4

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed:
  • Donate link: Please fix this invalid URI: ""
The official readme.txt might help

bulk-products-selling/bulk-products-selling.php 85% from 13 tests

The main PHP script in "Bulk Product Selling" version 1.0.2 is automatically included on every request by WordPress
It is important to fix the following:
  • Domain Path: The domain path folder does not exist ("/languages")
  • Text Domain: The text domain name must use dashes instead of underscores, and it must be lowercase

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin1,043 lines of code in 32 files:
LanguageFilesBlank linesComment linesLines of code
PHP303034331,035
JSON1005
CSS1003

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.45
Average class complexity8.65
▷ Minimum class complexity1.00
▷ Maximum class complexity44.00
Average method complexity2.50
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces6
Interfaces0
Traits1
Classes16
▷ Abstract classes00.00%
▷ Concrete classes16100.00%
▷ Final classes16.25%
Methods89
▷ Static methods1415.73%
▷ Public methods8595.51%
▷ Protected methods00.00%
▷ Private methods44.49%
Functions6
▷ Named functions350.00%
▷ Anonymous functions350.00%
Constants7
▷ Global constants685.71%
▷ Class constants114.29%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin