90% cta-section-custom-gb-block

Code Review | CTA Section Custom Block

WordPress plugin CTA Section Custom Block scored90%from 54 tests.

About plugin

  • Plugin page: cta-section-custo...
  • Plugin version: 1.0.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.9.3
  • WordPress version: 6.3.1
  • First release: Sep 22, 2021
  • Latest release: May 20, 2022
  • Number of updates: 6
  • Update frequency: every 40.5 days
  • Top authors: yagniksangani (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /709 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
Installer ran successfully

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

A check of server-side resources used by CTA Section Custom Block
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0239.98 ▼2.30
Dashboard /wp-admin3.32 ▲0.0148.18 ▼0.55
Posts /wp-admin/edit.php3.37 ▲0.0148.69 ▼3.73
Add New Post /wp-admin/post-new.php5.90 ▲0.0283.91 ▼21.72
Media Library /wp-admin/upload.php3.24 ▲0.0134.53 ▼1.41

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for CTA Section Custom Block
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,827 ▲8114.48 ▼0.122.07 ▲0.2043.48 ▼2.76
Dashboard /wp-admin2,203 ▲125.84 ▲0.93107.86 ▲3.8637.26 ▼7.79
Posts /wp-admin/edit.php2,086 ▼62.05 ▲0.0536.14 ▼1.3231.88 ▼2.40
Add New Post /wp-admin/post-new.php6,185 ▲4,65218.87 ▼4.41839.23 ▲149.2153.52 ▼2.37
Media Library /wp-admin/upload.php1,391 ▲34.18 ▼0.0298.43 ▼7.6243.14 ▼3.96

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts

Smoke tests Passed 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)
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 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
No output text or server-side errors detected on direct access of PHP files

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 96% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
5 plugin tags: call-to-action, block, text, description, cta

cta-section-custom-gb-block/plugin.php 92% from 13 tests

The principal PHP file in "CTA Section Custom Block" v. 1.0.1 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("cta-section-custom-gb-block.php" instead of "plugin.php")

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
Success! There were no dangerous files found in this plugin357 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript32255226
Sass37156
PHP2105946
Markdown17027
CSS2002

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.33
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%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There are no PNG files in this plugin