94% woo-photo-tags

Code Review | Woocommerce Photo Tags

WordPress plugin Woocommerce Photo Tags scored 94% from 54 tests.

About plugin

  • Plugin page: woo-photo-tags
  • Plugin version: 0.1.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.7-5.2.3
  • WordPress version: 5.8.1
  • First release: Mar 31, 2019
  • Latest release: Sep 9, 2019
  • Number of updates: 13
  • Update frequency: every 16.5 days
  • Top authors: paultb (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

10+ active / 735 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

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

A check of server-side resources used by Woocommerce Photo Tags
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.1246.87 ▲19.57
Dashboard /wp-admin3.06 ▲0.0059.32 ▲8.67
Posts /wp-admin/edit.php3.11 ▲0.0052.07 ▲0.55
Add New Post /wp-admin/post-new.php5.42 ▼0.02103.07 ▼599.62
Media Library /wp-admin/upload.php3.00 ▲0.0038.52 ▲4.19

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 11 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by Woocommerce Photo Tags
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,679 ▲8316.17 ▲0.3610.24 ▲0.7853.02 ▼0.38
Dashboard /wp-admin2,970 ▲335.92 ▲0.00158.35 ▼2.55125.76 ▼0.56
Posts /wp-admin/edit.php2,739 ▲32.69 ▲0.0072.42 ▼2.4598.93 ▼4.07
Add New Post /wp-admin/post-new.php1,683 ▲6818.76 ▼2.59413.56 ▲104.04119.44 ▲4.65
Media Library /wp-admin/upload.php1,807 ▼05.02 ▲0.01184.09 ▲9.55130.38 ▼1.37

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Uninstall script ran successfully

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 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/woo-photo-tags/woocommerce-photo-tags.php:24

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
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
8 plugin tags: lookbook, tag products, fashion e-commerce, home design, e-commerce...

woo-photo-tags/woocommerce-photo-tags.php 92% from 13 tests

The main PHP file in "Woocommerce Photo Tags" ver. 0.1.2 adds more information about the plugin and also serves as the entry point for this plugin
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("woo-photo-tags.php" instead of "woocommerce-photo-tags.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected8,620 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
CSS4128167,088
PHP3229961,030
JavaScript310514502

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions46
▷ Named functions46100.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
No PNG files were detected