84% easy-custom-post-type-ui

Code Review | Easy Custom Post Type UI

WordPress plugin Easy Custom Post Type UI scored 84% from 54 tests.

About plugin

  • Plugin page: easy-custom-post-...
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.5-6.3
  • WordPress version: 6.3.1
  • First release: Jan 30, 2023
  • Latest release: Aug 12, 2023
  • Number of updates: 46
  • Update frequency: every 4.3 days
  • Top authors: hashtechy (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 247 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

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

Server-side resources used by Easy Custom Post Type UI
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.80 ▼1.43
Dashboard /wp-admin3.32 ▼0.0643.96 ▼431.95
Posts /wp-admin/edit.php3.37 ▲0.0244.60 ▼2.00
Add New Post /wp-admin/post-new.php5.90 ▲0.0291.47 ▲7.07
Media Library /wp-admin/upload.php3.24 ▲0.0135.80 ▲0.55
CPT /wp-admin/admin.php?page=c-p-t3.4731.84
Taxonomies /wp-admin/admin.php?page=c-p-t-taxonomies3.3131.76

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 22 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Easy Custom Post Type UI
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,827 ▲8113.56 ▼0.861.64 ▼0.1341.26 ▼3.33
Dashboard /wp-admin2,233 ▲654.86 ▼0.95109.80 ▲4.9539.20 ▼1.88
Posts /wp-admin/edit.php2,119 ▲272.02 ▲0.0539.73 ▼2.2834.45 ▲3.33
Add New Post /wp-admin/post-new.php1,536 ▲123.36 ▲0.19590.40 ▼69.0958.65 ▲2.24
Media Library /wp-admin/upload.php1,418 ▲274.20 ▲0.0092.08 ▼15.0742.59 ▼2.90
CPT /wp-admin/admin.php?page=c-p-t1,8391.7428.7767.06
Taxonomies /wp-admin/admin.php?page=c-p-t-taxonomies1,2441.8527.5333.18

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 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 following issues need your attention
  • 5× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/easy-custom-post-type-ui/admin/partials/taxonomies-update.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/easy-custom-post-type-ui/admin/partials/taxonomies.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/easy-custom-post-type-ui/admin/partials/post-type-update.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/easy-custom-post-type-ui/admin/class-easy-custom-post-type-ui-admin.php:24
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/easy-custom-post-type-ui/admin/partials/post-type.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

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
5 plugin tags: custom post types, post, types, cpt, cms

easy-custom-post-type-ui/easy-custom-post-type-ui.php Passed 13 tests

The main PHP file in "Easy Custom Post Type UI" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
137 characters long description:
Easy Custom Post Type UI offers a simple-to-use interface for creating and maintaining taxonomies and custom post types for your website.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin5,163 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
CSS41,516353,425
PHP132154311,327
JavaScript22014411

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.52
Average class complexity11.14
▷ Minimum class complexity1.00
▷ Maximum class complexity65.00
Average method complexity3.96
▷ Minimum method complexity1.00
▷ Maximum method complexity39.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods24
▷ Static methods28.33%
▷ Public methods2083.33%
▷ Protected methods00.00%
▷ Private methods416.67%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
No PNG files were detected