10% advanced-custom-columns

Code Review | Advanced Custom Columns

WordPress plugin Advanced Custom Columns scored 10% from 54 tests.

About plugin

  • Plugin page: advanced-custom-c...
  • Plugin version: 1.1.5
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-4.1
  • WordPress version: 5.9.2
  • First release: May 31, 2017
  • Latest release: Jun 13, 2017
  • Number of updates: 3
  • Update frequency: every 4.7 days
  • Top authors: francois09 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 702 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
You still need to fix the following installer errors
  • The plugin did not install without errors
    • > Notice in wp-content/plugins/advanced-custom-columns/ACC_columns.php+114
    Trying to access array offset on value of type bool

Server metrics [RAM: ▼2.41MB] [CPU: ▼355.65ms] Passed 4 tests

This is a short check of server-side resources used by Advanced Custom Columns
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /1.96 ▼1.564.58 ▼48.62
Dashboard /wp-admin1.97 ▼1.434.55 ▼43.31
Posts /wp-admin/edit.php1.98 ▼1.665.80 ▼30.80
Add New Post /wp-admin/post-new.php1.97 ▼4.995.14 ▼1,299.88
Media Library /wp-admin/upload.php1.97 ▼1.325.61 ▼28.15
Custom columns /wp-admin/options-general.php?page=custom_admin_columns_for_sorting_and_filtering1.985.02

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Checking browser requirements for Advanced Custom Columns
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,754 ▼015.95 ▲0.717.78 ▲1.672.53 ▲0.33
Dashboard /wp-admin2,883 ▲226.12 ▼0.05120.10 ▼21.13156.20 ▼10.15
Posts /wp-admin/edit.php2,696 ▲53.24 ▼0.0066.22 ▼34.03146.22 ▼19.81
Add New Post /wp-admin/post-new.php1,755 ▲4421.66 ▲1.05476.54 ▲0.22158.08 ▲1.04
Media Library /wp-admin/upload.php1,697 ▼15.54 ▲0.06144.61 ▼1.86190.47 ▲1.36
Custom columns /wp-admin/options-general.php?page=custom_admin_columns_for_sorting_and_filtering1,0602.3857.68118.89

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • Uninstall procedure validation failed for this plugin
    • > Notice in wp-content/plugins/advanced-custom-columns/ACC_columns.php+114
    Trying to access array offset on value of type bool

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Please fix the following server-side errors
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=custom_admin_columns_for_sorting_and_filtering
    • > POST request to /wp-admin/admin-ajax.php
    • > Notice in wp-content/plugins/advanced-custom-columns/ACC_columns.php+119
    Trying to access array offset on value of type bool

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 items
  • 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/advanced-custom-columns/advanced-custom-columns.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/advanced-custom-columns/ACC_settings.php:117

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
4 plugin tags: filtering, custom post type, custom admin columns, sorting

advanced-custom-columns/advanced-custom-columns.php Passed 13 tests

The principal PHP file in "Advanced Custom Columns" v. 1.1.5 is loaded by WordPress automatically on each request
99 characters long description:
Add custom admin columns to post types to provide sorting and filtering through these extra columns

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
Good job! No executable or dangerous file extensions detected311 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP39094311

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.33
Average class complexity25.50
▷ Minimum class complexity2.00
▷ Maximum class complexity49.00
Average method complexity3.23
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods22
▷ Static methods940.91%
▷ Public methods22100.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

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
3 PNG files occupy 0.09MB with 0.05MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-2.png57.59KB23.56KB▼ 59.09%
assets/screenshot-1.png22.94KB10.64KB▼ 53.63%
assets/icon-256x256.png9.82KB3.48KB▼ 64.54%