78% acf-post-object-field-type-add-on

Code Review | ACF Post Object Field Type Add-on

WordPress plugin ACF Post Object Field Type Add-on scored 78% from 54 tests.

About plugin

  • Plugin page: acf-post-object-f...
  • Plugin version: 2.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-5.9.2
  • WordPress version: 5.9.2
  • First release: Dec 22, 2016
  • Latest release: Mar 12, 2022
  • Number of updates: 54
  • Update frequency: every 35.3 days
  • Top authors: davidbaumwald (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active / 3,103 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▼0.30MB] [CPU: ▼308.35ms] Passed 4 tests

An overview of server-side resources used by ACF Post Object Field Type Add-on
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.58 ▲0.0651.76 ▼0.18
Dashboard /wp-admin3.32 ▼0.0925.82 ▼8.07
Posts /wp-admin/edit.php3.39 ▼0.2631.53 ▼15.03
Add New Post /wp-admin/post-new.php6.11 ▼0.8778.12 ▼1,206.30
Media Library /wp-admin/upload.php3.33 ▲0.0322.06 ▼3.98
ACF Post Object Add-On /wp-admin/options-general.php?page=de_acfpoftao3.2620.82

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 6 new files
Database: no new tables, 1 new option
New WordPress options
recovery_mode_email_last_sent

Browser metrics Passed 4 tests

A check of browser resources used by ACF Post Object Field Type Add-on
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,768 ▲1416.22 ▲0.195.70 ▼0.202.41 ▼0.53
Dashboard /wp-admin2,897 ▲366.15 ▼0.01118.43 ▼16.59181.91 ▲17.57
Posts /wp-admin/edit.php2,693 ▼13.26 ▲0.0365.40 ▲1.00142.60 ▲1.77
Add New Post /wp-admin/post-new.php1,703 ▲1321.44 ▲0.70476.81 ▲4.61217.45 ▲54.02
Media Library /wp-admin/upload.php1,703 ▲55.51 ▲0.07140.02 ▼7.88196.33 ▲2.25
ACF Post Object Add-On /wp-admin/options-general.php?page=de_acfpoftao620.940.07101.49

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • The uninstall procedure has failed, leaving 1 option in the database
    • recovery_mode_email_last_sent

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=de_acfpoftao
    • > Error in wp-content/plugins/acf-post-object-field-type-add-on/de-acf-post-object-addon.php+182
    Uncaught Error: Call to undefined function acf_get_field_groups() in wp-content/plugins/acf-post-object-field-type-add-on/de-acf-post-object-addon.php:182
    Stack trace:
    #0 wp-content/plugins/acf-post-object-field-type-add-on/de-acf-post-object-addon.php(107): DE_ACF_Post_Object_Addon_Plugin->get_acf_append_field_options()
    #1 wp-includes/class-wp-hook.php(307): DE_ACF_Post_Object_Addon_Plugin->option_page_assets()
    #2 wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters()
    #3 wp-includes/plugin.php(474): WP_Hook->do_action()
    #4 wp-admin/admin-header.php(139): do_action()
    #5 wp-admin/admin.php(239): require_once('/var/www/wordpr...')
    #6 wp-admin/options-general.php(10): require_once('/var/www/wordpr...')
    #7 {main}
    thrown

SRP Passed 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
No output text or server-side errors detected on direct access of PHP files

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There are user-side issues you should fix
    • > GET request to /wp-admin/options-general.php?page=de_acfpoftao
    • > Network (severe)
    wp-admin/options-general.php?page=de_acfpoftao - Failed to load resource: the server responded with a status of 500 (Internal Server Error)

Optimizations

Plugin configuration 93% from 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: acf, acf post object, acf post title, post object field type

acf-post-object-field-type-add-on/de-acf-post-object-addon.php 85% from 13 tests

The principal PHP file in "ACF Post Object Field Type Add-on" v. 2.0.2 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("acf-post-object-field-type-add-on.php" instead of "de-acf-post-object-addon.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin490 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP15910238
CSS180114
PO File1212375
JavaScript1104963

PHP code Passed 2 tests

A short review 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.33
Average class complexity25.00
▷ Minimum class complexity25.00
▷ Maximum class complexity25.00
Average method complexity2.71
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods14
▷ Static methods17.14%
▷ Public methods14100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin