90% content-visibility-for-divi-builder

Code Review | Content Visibility for Divi Builder

WordPress plugin Content Visibility for Divi Builder scored90%from 54 tests.

About plugin

  • Plugin page: content-visibilit...
  • Plugin version: 3.22
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.9
  • WordPress version: 6.3.1
  • First release: Feb 28, 2016
  • Latest release: Mar 9, 2023
  • Number of updates: 75
  • Update frequency: every 34.2 days
  • Top authors: jhorowitz (100%)

Code review

54 tests

User reviews

95 reviews

Install metrics

3,000+ active /58,581 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 gracefully, with no errors

Server metrics [RAM: ▲0.14MB] [CPU: ▼3.39ms] Passed 4 tests

This is a short check of server-side resources used by Content Visibility for Divi Builder
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.1341.93 ▲1.31
Dashboard /wp-admin3.44 ▲0.1444.83 ▼3.61
Posts /wp-admin/edit.php3.55 ▲0.2045.51 ▼3.67
Add New Post /wp-admin/post-new.php6.04 ▲0.1691.56 ▼7.57
Media Library /wp-admin/upload.php3.36 ▲0.1435.36 ▲2.87
Module Extender API Reference /wp-admin/tools.php?page=module-extender-for-divi-builder-api-reference3.3329.82

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 6 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
content_visibility_for_divi_builder_version
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Content Visibility for Divi Builder
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,826 ▲5513.21 ▼1.161.66 ▼0.4143.57 ▼1.86
Dashboard /wp-admin2,235 ▲534.91 ▼0.96113.45 ▲10.7047.87 ▲6.15
Posts /wp-admin/edit.php2,115 ▲262.06 ▲0.0540.95 ▲5.0040.60 ▲4.99
Add New Post /wp-admin/post-new.php1,538 ▲2423.11 ▲5.50627.80 ▲8.9555.67 ▲2.02
Media Library /wp-admin/upload.php1,411 ▲204.23 ▲0.0398.03 ▼4.6744.46 ▼1.86
Module Extender API Reference /wp-admin/tools.php?page=module-extender-for-divi-builder-api-reference8652.0726.5739.44

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_theysaidso_widget
    • content_visibility_for_divi_builder_version
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Attributes that need to be fixed:
  • Tags: You are using too many tags: 14 tag instead of maximum 10
The official readme.txt is a good inspiration

content-visibility-for-divi-builder/content-visibility-for-divi-builder.php Passed 13 tests

The main PHP file in "Content Visibility for Divi Builder" ver. 3.22 adds more information about the plugin and also serves as the entry point for this plugin
100 characters long description:
Allows Sections and Modules to be displayed/hidden based on the outcome of a PHP boolean expression.

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 plugin530 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP17545425
JavaScript2147100
CSS1005

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.59
Average class complexity11.00
▷ Minimum class complexity11.00
▷ Maximum class complexity11.00
Average method complexity2.43
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions23
▷ Named functions417.39%
▷ Anonymous functions1982.61%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG images were found in this plugin