84% pixelshop-integration

Code Review | Pixelshop Integration

WordPress plugin Pixelshop Integration scored84%from 54 tests.

About plugin

  • Plugin page: pixelshop-integra...
  • Plugin version: 1.3.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.0-4.5.1
  • WordPress version: 6.3.1
  • First release: Dec 7, 2015
  • Latest release: Dec 21, 2016
  • Number of updates: 16
  • Update frequency: every 23.8 days
  • Top authors: Rafael Mor (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /809 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.09MB] [CPU: ▼2.48ms] Passed 4 tests

Server-side resources used by Pixelshop Integration
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0636.86 ▼2.31
Dashboard /wp-admin3.41 ▲0.1050.56 ▼2.65
Posts /wp-admin/edit.php3.52 ▲0.1751.38 ▲5.15
Add New Post /wp-admin/post-new.php5.99 ▲0.1086.91 ▼6.64
Media Library /wp-admin/upload.php3.33 ▲0.1039.01 ▲1.68
Export /wp-admin/admin.php?page=pixelshop-export3.2935.15
Pixelshop /wp-admin/admin.php?page=pixelshop3.2935.90

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by Pixelshop Integration
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲7913.43 ▼1.221.64 ▼0.4841.51 ▼2.10
Dashboard /wp-admin2,234 ▲464.84 ▼0.97104.90 ▼15.0237.65 ▼5.87
Posts /wp-admin/edit.php2,117 ▲312.05 ▲0.0339.97 ▼0.5636.79 ▲2.23
Add New Post /wp-admin/post-new.php1,559 ▲2623.12 ▼0.28658.87 ▼29.0850.56 ▼16.48
Media Library /wp-admin/upload.php1,416 ▲314.30 ▲0.0796.47 ▼9.4442.13 ▼3.00
Export /wp-admin/admin.php?page=pixelshop-export8142.0726.7127.76
Pixelshop /wp-admin/admin.php?page=pixelshop8672.0225.3832.73

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments

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
Even though no errors were found, this is by no means an exhaustive test

SRP 50% 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
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/pixelshop-integration/core/snippets/conversions.php:26
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/pixelshop-integration/core/controllers/export.php:27

User-side errors Passed 1 test

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

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: pixelshop

pixelshop-integration/pixelshop.php 92% from 13 tests

The main PHP file in "Pixelshop Integration" ver. 1.3.0 adds more information about the plugin and also serves as the entry point for this plugin
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("pixelshop-integration.php" instead of "pixelshop.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected665 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP5167243491
CSS14293
PO File1232378
Markdown1203

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity14.50
▷ Minimum class complexity1.00
▷ Maximum class complexity31.00
Average method complexity2.93
▷ Minimum method complexity1.00
▷ Maximum method complexity15.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods28
▷ Static methods00.00%
▷ Public methods28100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 PNG file occupies 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/export-products.png6.84KB2.84KB▼ 58.40%