73% acpt-lite

Code Review | Custom post types for Wordpress – ACPT Lite

WordPress plugin Custom post types for Wordpress – ACPT Lite scored 73% from 54 tests.

About plugin

  • Plugin page: acpt-lite
  • Plugin version: 1.0.17
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.1-6.2
  • WordPress version: 6.3.1
  • First release: Dec 1, 2021
  • Latest release: Apr 24, 2023
  • Number of updates: 31
  • Update frequency: every 16.4 days
  • Top authors: mauretto1978 (100%)

Code review

54 tests

User reviews

17 reviews

Install metrics

40+ active / 3,390 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲1.23MB] [CPU: ▲7.90ms] Passed 4 tests

A check of server-side resources used by Custom post types for Wordpress – ACPT Lite
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /4.92 ▲1.4758.06 ▲19.33
Dashboard /wp-admin4.83 ▲1.5364.08 ▲19.67
Posts /wp-admin/edit.php4.85 ▲1.4974.21 ▲9.89
Add New Post /wp-admin/post-new.php6.31 ▲0.4275.47 ▼17.28
Media Library /wp-admin/upload.php4.76 ▲1.5456.22 ▲24.03
Custom Post Types /wp-admin/admin.php?page=advanced-custom-post-type-lite4.6150.34

Server storage [IO: ▲7.62MB] [DB: ▲0.02MB] Passed 3 tests

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 456 new files
Database: 17 new tables, 6 new options
New tables
wp_acpt_lite_custom_post_type
wp_acpt_lite_taxonomy_meta_box
wp_acpt_lite_woocommerce_product_data_option
wp_acpt_lite_custom_post_type_option
wp_acpt_lite_user_field_option
wp_acpt_lite_woocommerce_product_data
wp_acpt_lite_custom_post_type_meta_box
wp_acpt_lite_taxonomy
wp_acpt_lite_user_meta_box
wp_acpt_lite_custom_post_type_import
...
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Custom post types for Wordpress – ACPT Lite
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,868 ▲13313.27 ▼1.291.73 ▼0.0740.55 ▼7.08
Dashboard /wp-admin2,259 ▲685.83 ▲0.95108.76 ▲6.6573.93 ▲35.05
Posts /wp-admin/edit.php2,157 ▲681.99 ▲0.0239.01 ▼13.4438.60 ▼7.52
Add New Post /wp-admin/post-new.php6,498 ▲4,96520.98 ▼2.40883.22 ▲209.8436.77 ▼20.56
Media Library /wp-admin/upload.php1,459 ▲714.24 ▲0.04119.32 ▲21.1546.15 ▼0.48
Custom Post Types /wp-admin/admin.php?page=advanced-custom-post-type-lite1,1644.29149.93105.22
Taxonomies /wp-admin/admin.php?page=advanced-custom-post-type-lite#/taxonomies1,1064.10118.2045.00
User meta /wp-admin/admin.php?page=advanced-custom-post-type-lite#/user-meta1,0433.8562.3434.86
Settings /wp-admin/admin.php?page=advanced-custom-post-type-lite#/settings1,1104.9880.5543.32

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • The uninstall procedure failed, leaving 17 tables in the database
    • wp_acpt_lite_custom_post_type_meta_box
    • wp_acpt_lite_user_meta_box
    • wp_acpt_lite_user_field_option
    • wp_acpt_lite_settings
    • wp_acpt_lite_taxonomy_pivot
    • wp_acpt_lite_woocommerce_product_data_field
    • wp_acpt_lite_woocommerce_product_data_option
    • wp_acpt_lite_custom_post_type
    • wp_acpt_lite_custom_post_type_import
    • wp_acpt_lite_taxonomy_meta_box
    • ...
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options

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
Good news, no errors were detected

SRP 50% from 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
The following issues need your attention
  • 43× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'ACPT_Lite\\Core\\Generators\\UserFields\\AbstractField' not found in wp-content/plugins/acpt-lite/src/Core/Generators/UserFields/EmailField.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'ACPT_Lite\\Core\\Shortcodes\\Fields\\AbstractField' not found in wp-content/plugins/acpt-lite/src/Core/Shortcodes/Fields/SelectField.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'ACPT_Lite\\Core\\Models\\Abstracts\\AbstractModel' not found in wp-content/plugins/acpt-lite/src/Core/Models/MetaField/MetaBoxFieldOptionModel.php:16
    • > PHP Fatal error
      Uncaught Error: Class 'ACPT_Lite\\Core\\Models\\Abstracts\\AbstractModel' not found in wp-content/plugins/acpt-lite/src/Core/Models/Taxonomy/TaxonomyModel.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'ACPT_Lite\\Core\\Generators\\UserFields\\AbstractField' not found in wp-content/plugins/acpt-lite/src/Core/Generators/UserFields/SelectField.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'ACPT_Lite\\Core\\Shortcodes\\Fields\\AbstractField' not found in wp-content/plugins/acpt-lite/src/Core/Shortcodes/Fields/TextField.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'ACPT_Lite\\Core\\Generators\\CustomPostTypeFields\\AbstractField' not found in wp-content/plugins/acpt-lite/src/Core/Generators/CustomPostTypeFields/EmailField.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'ACPT_Lite\\Core\\Models\\Abstracts\\AbstractMetaBoxModel' not found in wp-content/plugins/acpt-lite/src/Core/Models/User/UserMetaBoxModel.php:16
    • > PHP Fatal error
      Uncaught Error: Class 'ACPT_Lite\\Core\\Generators\\TaxonomyFields\\AbstractTaxonomyField' not found in wp-content/plugins/acpt-lite/src/Core/Generators/TaxonomyFields/EmailField.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'ACPT_Lite\\Core\\Models\\Abstracts\\AbstractModel' not found in wp-content/plugins/acpt-lite/src/Core/Models/CustomPostType/CustomPostTypeModel.php:19

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
5 plugin tags: custom post types, taxonomies, taxonomy, custom post type, meta box

acpt-lite/advanced-custom-post-type-lite.php 77% from 13 tests

The entry point to "Custom post types for Wordpress – ACPT Lite" version 1.0.17 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
  • Domain Path: The domain path folder does not exist ("/advanced-custom-post-type-lite")
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("acpt-lite.php" instead of "advanced-custom-post-type-lite.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
Everything looks great! No dangerous files found in this plugin46,466 lines of code in 342 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript974,7024,38818,486
PHP1062,7377,64113,490
HTML323984935,444
CSS207331044,138
Handlebars45507942,236
JSON12301,006
Sass17400991830
Markdown72750697
YAML2331101
XML21029
SVG1005
Bourne Shell1004

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.45
Average class complexity16.93
▷ Minimum class complexity1.00
▷ Maximum class complexity227.00
Average method complexity2.54
▷ Minimum method complexity1.00
▷ Maximum method complexity36.00
Code structure
Namespaces29
Interfaces3
Traits1
Classes90
▷ Abstract classes1112.22%
▷ Concrete classes7987.78%
▷ Final classes11.27%
Methods972
▷ Static methods52153.60%
▷ Public methods83986.32%
▷ Protected methods424.32%
▷ Private methods919.36%
Functions37
▷ Named functions2670.27%
▷ Anonymous functions1129.73%
Constants38
▷ Global constants25.26%
▷ Class constants3694.74%
▷ Public constants36100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
44 PNG files occupy 2.55MB with 1.38MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/vendor/owl.carousel/docs/assets/img/bird_blue_32.png1.32KB0.33KB▼ 75.15%
assets/static/css/select2/select2.png0.60KB0.99KB0.00%
screenshot-4.png184.34KB67.98KB▼ 63.12%
assets/screenshot-3.png108.82KB41.62KB▼ 61.76%
assets/vendor/owl.carousel/docs/assets/img/feature-zombie.png9.44KB2.73KB▼ 71.10%