10% esell

Code Review | Esell

WordPress plugin Esell scored10%from 54 tests.

About plugin

  • Plugin page: esell
  • Plugin version: 5.4.4
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-5.4
  • WordPress version: 6.3.1
  • First release: Jul 14, 2020
  • Latest release: Sep 16, 2020
  • Number of updates: 42
  • Update frequency: every 1.6 days
  • Top authors: wwyc (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /405 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
It is recommended to fix the following installer errors
  • Install procedure had errors
    • > Warning in wp-content/plugins/esell/Esell.php+50
    require_once(wp-content/plugins/esell//includes/init.class.php): failed to open stream: No such file or directory

Server metrics [RAM: ▲0.00MB] [CPU: ▼6.19ms] Passed 4 tests

This is a short check of server-side resources used by Esell
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0037.02 ▼19.89
Dashboard /wp-admin3.31 ▲0.0046.51 ▼3.63
Posts /wp-admin/edit.php3.36 ▲0.0047.39 ▼1.09
Add New Post /wp-admin/post-new.php5.89 ▲0.0092.43 ▲0.19
Media Library /wp-admin/upload.php3.23 ▲0.0034.72 ▼0.15

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 175 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
db_upgraded
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Esell
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.69 ▼0.611.74 ▼0.1940.77 ▼4.64
Dashboard /wp-admin2,206 ▲215.91 ▲1.03103.28 ▲1.5039.39 ▼6.02
Posts /wp-admin/edit.php2,092 ▲62.02 ▲0.0240.55 ▼0.1434.76 ▼1.58
Add New Post /wp-admin/post-new.php1,514 ▼1917.89 ▼5.49694.80 ▲60.2563.50 ▲6.37
Media Library /wp-admin/upload.php1,388 ▼34.16 ▼0.0295.90 ▲2.4840.97 ▼3.62

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
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 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
Please fix the following items
  • 129× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      require_once(): Failed opening required 'DEALBAO_PLUGIN_DIR/vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/esell/includes/dealbaoSetting/dealbaoSettingCurl.class.php on line 9
    • > PHP Fatal error
      Uncaught Error: Class 'Dealbao\\Open\\core\\Api' not found in wp-content/plugins/esell/vendor/dealbao/service/src/Open/lib/order/Order.php:7
    • > PHP Warning
      include(): Failed opening 'DEALBAO_PLUGIN_DIR/includes/Language.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/esell/includes/dealbaoGoods/dealbaoGoodsCurl.class.php on line 9
    • > PHP Warning
      require_once(../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/esell/vendor/dealbao/service/demo/Order.php on line 2
    • > PHP Fatal error
      Uncaught Error: Class 'Dealbao\\Open\\core\\Api' not found in wp-content/plugins/esell/vendor/dealbao/service/src/Open/lib/goods/Cate.php:4
    • > PHP Warning
      Use of undefined constant DEALBAO_DIR_URL - assumed 'DEALBAO_DIR_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/esell/includes/dealbaoCategory/dealbaoCategoryBind.php on line 47
    • > PHP Warning
      Use of undefined constant DEALBAO_PLUGIN_DIR - assumed 'DEALBAO_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/esell/includes/dealbaoCollect/dealbaoCollectCurl.class.php on line 10
    • > PHP Warning
      require_once(../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/esell/vendor/dealbao/service/demo/Cate.php on line 2
    • > PHP Warning
      require_once(DEALBAO_PLUGIN_DIR/vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/esell/includes/dealbaoSetting/dealbaoSettingCurl.class.php on line 9
    • > PHP Warning
      Use of undefined constant DEALBAO_DIR_URL - assumed 'DEALBAO_DIR_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/esell/includes/dealbaoCollect/dealbaoCollectList.php on line 40

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Please fix the following attributes:
  • Screenshots: These screenshots require images: #1 (This screen shot description corresponds to screenshot-1.(png|jpg|jpeg|gif). Note that the screenshot is stored in the /assets directory.), #2 (This is the second screen shot)
Please take inspiration from this readme.txt

esell/Esell.php 85% from 13 tests

"Esell" version 5.4.4's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Text Domain: The text domain should only use lowercase characters and dashes
  • Main file name: The principal plugin file should be the same as the plugin slug ("esell.php" instead of "Esell.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
Everything looks great! No dangerous files found in this plugin17,532 lines of code in 140 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript134393688,301
PHP991,5241,5265,529
CSS8127371,409
C118847879
LESS22220584
JSON600233
PO File175167163
C/C++ Header24046132
Markdown4630116
reStructuredText19413597
m41111141
YAML15035
XML11013

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity6.48
▷ Minimum class complexity1.00
▷ Maximum class complexity100.00
Average method complexity2.66
▷ Minimum method complexity1.00
▷ Maximum method complexity44.00
Code structure
Namespaces17
Interfaces4
Traits0
Classes58
▷ Abstract classes00.00%
▷ Concrete classes58100.00%
▷ Final classes23.45%
Methods246
▷ Static methods114.47%
▷ Public methods24298.37%
▷ Protected methods10.41%
▷ Private methods31.22%
Functions73
▷ Named functions1013.70%
▷ Anonymous functions6386.30%
Constants9
▷ Global constants444.44%
▷ Class constants555.56%
▷ Public constants5100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
15 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
lib/zTree/css/zTreeStyle/img/diy/1_close.png0.59KB0.33KB▼ 42.93%
lib/zTree/css/zTreeStyle/img/diy/9.png0.46KB0.32KB▼ 30.84%
images/bg.png0.24KB0.26KB0.00%
lib/zTree/css/metroStyle/img/metro.png5.16KB2.61KB▼ 49.48%
lib/zTree/css/zTreeStyle/img/diy/2.png0.56KB0.41KB▼ 26.67%