100% mage-product-select-for-acf

Code Review | Mage Product Select for ACF

WordPress plugin Mage Product Select for ACF scored 100% from 54 tests.

About plugin

  • Plugin page: mage-product-sele...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-3.8.1
  • WordPress version: 5.8.1
  • First release: Oct 2, 2016
  • Latest release: Oct 2, 2016
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: nickwanhere (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 354 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
Install script ran successfully

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

An overview of server-side resources used by Mage Product Select for ACF
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.1234.45 ▲12.46
Dashboard /wp-admin3.07 ▲0.0144.47 ▲1.56
Posts /wp-admin/edit.php3.12 ▲0.0143.87 ▲5.06
Add New Post /wp-admin/post-new.php5.43 ▼0.0187.10 ▼691.40
Media Library /wp-admin/upload.php3.01 ▲0.0130.93 ▼4.41

Server storage [IO: ▲0.02MB] [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, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for Mage Product Select for ACF
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,679 ▲8315.99 ▲0.408.91 ▼0.8250.75 ▲0.43
Dashboard /wp-admin2,983 ▲526.05 ▲0.12135.10 ▼14.04109.73 ▼3.90
Posts /wp-admin/edit.php2,736 ▼32.83 ▲0.1362.85 ▲1.9691.67 ▲2.96
Add New Post /wp-admin/post-new.php1,672 ▲5718.85 ▼2.51371.12 ▲86.71113.52 ▼4.34
Media Library /wp-admin/upload.php1,807 ▼35.02 ▼0.03150.83 ▲6.81117.36 ▼1.40

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Uninstaller ran successfully

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

SRP Passed 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 SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
3 plugin tags: product, magento, acf

mage-product-select-for-acf/acf-magento_product.php 92% from 13 tests

The main PHP file in "Mage Product Select for ACF" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
Please take the time to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("mage-product-select-for-acf.php" instead of "acf-magento_product.php")

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
Good job! No executable or dangerous file extensions detected138 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP219938686
Markdown619035
JavaScript1252917

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity5.50
▷ Minimum class complexity2.00
▷ Maximum class complexity9.00
Average method complexity2.29
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
PNG images were not found in this plugin