84% ccbpress-core

Code Review | Church Data Connect for Church Community Builder

WordPress plugin Church Data Connect for Church Community Builder scored84%from 54 tests.

About plugin

  • Plugin page: ccbpress-core
  • Plugin version: 1.5.1
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3-6.4
  • WordPress version: 6.3.1
  • First release: Dec 7, 2015
  • Latest release: Nov 29, 2023
  • Number of updates: 56
  • Update frequency: every 52.1 days
  • Top authors: danielmilner (82.14%)firetree (19.64%)

Code review

54 tests

User reviews

1 review

Install metrics

300+ active /12,825 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.86MB] [CPU: ▼0.28ms] 75% from 4 tests

A check of server-side resources used by Church Data Connect for Church Community Builder
Please fix the following
  • CPU: The total CPU usage must kept under 500.00ms (currently 1,595.66ms on /wp-admin/admin.php?page=ccbpress-addons)
PageMemory (MB)CPU Time (ms)
Home /4.21 ▲0.7446.26 ▲4.83
Dashboard /wp-admin4.20 ▲0.8551.00 ▼12.56
Posts /wp-admin/edit.php4.31 ▲0.9556.40 ▲9.16
Add New Post /wp-admin/post-new.php6.83 ▲0.9499.33 ▼2.31
Media Library /wp-admin/upload.php4.13 ▲0.9041.10 ▲8.94
Tools /wp-admin/admin.php?page=ccbpress-tools4.0934.44
Settings /wp-admin/admin.php?page=ccbpress-settings4.0938.41
Welcome /wp-admin/admin.php?page=ccbpress4.0934.92
Add-ons /wp-admin/admin.php?page=ccbpress-addons4.111,595.66

Server storage [IO: ▲1.28MB] [DB: ▲0.01MB] Passed 3 tests

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 104 new files
Database: no new tables, 10 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
ccbpress_settings
ccbpress_ccb
ccbpress_licenses
db_upgraded
widget_recent-posts
ccbpress_core_db_version
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Church Data Connect for Church Community Builder
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,030 ▲28313.45 ▼1.268.95 ▲7.2039.57 ▼3.44
Dashboard /wp-admin2,323 ▲1495.62 ▼0.0495.23 ▲9.8342.30 ▲0.27
Posts /wp-admin/edit.php2,228 ▲1282.02 ▲0.0141.35 ▲5.0535.81 ▼1.49
Add New Post /wp-admin/post-new.php6,237 ▲4,71119.40 ▼3.68817.15 ▲173.0863.05 ▲5.18
Media Library /wp-admin/upload.php1,531 ▲1374.20 ▲0.0497.99 ▲3.1942.75 ▲0.09
Tools /wp-admin/admin.php?page=ccbpress-tools8842.0425.6021.53
Settings /wp-admin/admin.php?page=ccbpress-settings1,0412.1727.0628.12
Welcome /wp-admin/admin.php?page=ccbpress1,0352.1326.4361.19
Add-ons /wp-admin/admin.php?page=ccbpress-addons9622.0625.1531.82

Uninstaller [IO: ▲0.00MB] [DB: ▲0.01MB] 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 10 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • ccbpress_settings
    • ccbpress_licenses
    • ccbpress_ccb
    • ccbpress_core_db_version
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Please take a closer look at the following
  • 7× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Notice
      Undefined variable: template in wp-content/plugins/ccbpress-core/templates/group-info.php on line 6
    • > PHP Fatal error
      Uncaught Error: Call to a member function show_group_image() on null in wp-content/plugins/ccbpress-core/templates/group-info.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'CCBPress\\Library\\BackgroundProcessing\\WP_Async_Request' not found in wp-content/plugins/ccbpress-core/lib/wp-background-processing/wp-background-process.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ccbpress-core/includes/schedule-get.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ccbpress-core/includes/styles.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'CCBPress\\Library\\BackgroundProcessing\\WP_Background_Process' not found in wp-content/plugins/ccbpress-core/includes/class-ccbpress-background-get.php:19
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ccbpress-core/includes/admin/admin-styles.php:7

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
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
6 plugin tags: pushpay, gutenberg, church, church community builder, chms...

ccbpress-core/ccbpress-core.php Passed 13 tests

Analyzing the main PHP file in "Church Data Connect for Church Community Builder" version 1.5.1
73 characters long description:
Display information from Church Community Builder on your WordPress site.

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
No dangerous file extensions were detected23,940 lines of code in 84 files:
LanguageFilesBlank linesComment linesLines of code
JSON80016,009
PHP421,4052,6224,764
JavaScript162351692,526
CSS98533495
Sass783113
Markdown113022
SVG10011

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity17.22
▷ Minimum class complexity1.00
▷ Maximum class complexity85.00
Average method complexity3.21
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes36
▷ Abstract classes25.56%
▷ Concrete classes3494.44%
▷ Final classes00.00%
Methods266
▷ Static methods5219.55%
▷ Public methods20777.82%
▷ Protected methods269.77%
▷ Private methods3312.41%
Functions12
▷ Named functions866.67%
▷ Anonymous functions433.33%
Constants6
▷ Global constants466.67%
▷ Class constants233.33%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
11 PNG files occupy 0.24MB with 0.13MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
lib/chosen/chosen-sprite.png0.53KB0.88KB0.00%
assets/images/ccbpress_mark.png5.99KB2.75KB▼ 54.05%
assets/images/getting_started_api_user.png24.88KB7.13KB▼ 71.34%
assets/images/getting_started_connection_settings.png41.91KB13.73KB▼ 67.24%
assets/images/blocks.png31.40KB8.73KB▼ 72.20%