78% cpt-mapper

Code Review | Custom Post Type Mapper - Register post ypes, taxonomies, meta boxes without coding

WordPress plugin Custom Post Type Mapper - Register post ypes, taxonomies, meta boxes without coding scored78%from 54 tests.

About plugin

  • Plugin page: cpt-mapper
  • Plugin version: 0.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9-5.0
  • WordPress version: 6.3.1
  • First release: Nov 26, 2018
  • Latest release: Dec 8, 2018
  • Number of updates: 12
  • Update frequency: every 1.8 days
  • Top authors: rajasaad (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /647 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.04MB] [CPU: ▼6.75ms] Passed 4 tests

Analyzing server-side resources used by Custom Post Type Mapper - Register post ypes, taxonomies, meta boxes without coding
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0339.58 ▲1.30
Dashboard /wp-admin3.36 ▲0.0145.76 ▼15.53
Posts /wp-admin/edit.php3.41 ▲0.0546.37 ▲0.76
Add New Post /wp-admin/post-new.php5.96 ▲0.0784.11 ▼13.54
Media Library /wp-admin/upload.php3.28 ▲0.0536.78 ▲2.26
Meta Fields /wp-admin/admin.php?page=meta-mapper3.2933.10
CPT Mapper /wp-admin/admin.php?page=cpt-mapper3.2930.75
Taxonomies /wp-admin/admin.php?page=taxonomy-mapper3.2730.52

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 14 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by Custom Post Type Mapper - Register post ypes, taxonomies, meta boxes without coding
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,845 ▲8414.72 ▲0.361.89 ▲0.2943.25 ▼1.78
Dashboard /wp-admin2,226 ▲455.61 ▼0.1082.62 ▼21.0542.13 ▲4.07
Posts /wp-admin/edit.php2,134 ▲342.04 ▲0.0634.65 ▼0.7030.23 ▼2.38
Add New Post /wp-admin/post-new.php1,553 ▲2023.08 ▲0.33657.24 ▼17.2946.89 ▼14.80
Media Library /wp-admin/upload.php1,428 ▲284.20 ▲0.08102.24 ▼11.1744.69 ▼4.52
Meta Fields /wp-admin/admin.php?page=meta-mapper8262.0228.7731.98
CPT Mapper /wp-admin/admin.php?page=cpt-mapper8362.0523.3822.18
Taxonomies /wp-admin/admin.php?page=taxonomy-mapper8352.0424.3422.85

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Almost there! Just fix the following items
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/cpt-mapper/cpt-mapper.php
  • 7× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/cpt-mapper/fragments/admin-page-content.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/cpt-mapper/fragments/post-type-register.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/cpt-mapper/fragments/taxonomy-register.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/cpt-mapper/fragments/admin-page-taxonomy-content.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/cpt-mapper/fragments/meta-callback.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/cpt-mapper/fragments/action-hooks.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/cpt-mapper/fragments/admin-page-meta-content.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
9 plugin tags: cms, custom post types, meta boxes, taxonomy, custom fields...

cpt-mapper/cpt-mapper.php 85% from 13 tests

The entry point to "Custom Post Type Mapper - Register post ypes, taxonomies, meta boxes without coding" version 0.0.1 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Description: Please keep the plugin description shorter than 140 characters (currently 144 characters long)
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

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
No dangerous file extensions were detected818 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP87638642
CSS13917146
JavaScript19030

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions13
▷ Named functions13100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin