84% super-easy-stock-manager

Code Review | Super Easy Stock Manager

WordPress plugin Super Easy Stock Manager scored84%from 54 tests.

About plugin

  • Plugin page: super-easy-stock-...
  • Plugin version: 1.3.6
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.4.0-6.1.1
  • WordPress version: 6.3.1
  • First release: Dec 2, 2022
  • Latest release: Dec 21, 2022
  • Number of updates: 9
  • Update frequency: every 2.1 days
  • Top authors: dansart (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /251 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

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

This is a short check of server-side resources used by Super Easy Stock Manager
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.60 ▲1.84
Dashboard /wp-admin3.31 ▲0.0142.87 ▼3.39
Posts /wp-admin/edit.php3.36 ▲0.0145.19 ▼3.59
Add New Post /wp-admin/post-new.php5.90 ▲0.0183.28 ▼20.67
Media Library /wp-admin/upload.php3.24 ▲0.0133.37 ▲2.77

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 29 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

Super Easy Stock Manager: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,952 ▲20614.55 ▲0.2515.68 ▲13.7248.18 ▲7.97
Dashboard /wp-admin2,203 ▲125.81 ▲0.9297.85 ▼11.0838.89 ▼5.23
Posts /wp-admin/edit.php2,092 ▼01.97 ▼0.0539.22 ▼2.3535.72 ▼0.38
Add New Post /wp-admin/post-new.php1,536 ▲1023.22 ▲0.15656.65 ▼38.2161.24 ▲3.37
Media Library /wp-admin/upload.php1,391 ▲64.42 ▲0.21100.56 ▼1.4242.90 ▼1.76

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

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

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'Super_Easy_Stock_Manager_Helper' not found in wp-content/plugins/super-easy-stock-manager/include/classes/sesm-admin.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'Super_Easy_Stock_Manager_Helper' not found in wp-content/plugins/super-easy-stock-manager/include/classes/sesm.php:10

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Please fix the following attributes:
  • Screenshots: These screenshots require images: #1 (The get product screen. A single input field to search for a product. Below, are the three types of WooCommerce products), #2 (The update-stock screen. With the + and - buttons, or by keyboard, you can set the desired amount to add or remove and scan the SKU to confirm the change), #3 (the update-price screen. You can set the regular as well as the sale price.), #4 (The get product screen on a smartphone. With the camera button at the bottom you can use the internal camera as a scanner.), #5 (The get product screen on a smartphone with the scan app open.)
Please take inspiration from this readme.txt

super-easy-stock-manager/super-easy-stock-manager.php 92% from 13 tests

This is the main PHP file of "Super Easy Stock Manager" version 1.3.6, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Requires at least: The required version number did not match the one declared in readme.txt ("5.5.3" instead of "5.4.0")

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
Everything looks great! No dangerous files found in this plugin1,988 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
PHP762285504
Sass1992470
JavaScript559176409
CSS210910367
PO File13841119
HTML5150118
JSON1001

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity17.60
▷ Minimum class complexity1.00
▷ Maximum class complexity57.00
Average method complexity4.12
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods28
▷ Static methods00.00%
▷ Public methods28100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions00.00%
▷ Anonymous functions3100.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.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
There were not PNG files found in your plugin