10% cellarweb-privacy-and-security-options

Code Review | CellarWeb Privacy and Security Options

WordPress plugin CellarWeb Privacy and Security Options scored10%from 54 tests.

About plugin

  • Plugin page: cellarweb-privacy...
  • Plugin version: 4.14
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.6-6.4
  • WordPress version: 6.3.1
  • First release: Jan 2, 2020
  • Latest release: Nov 30, 2023
  • Number of updates: 36
  • Update frequency: every 39.7 days
  • Top authors: rhellewell@gmail.com (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,801 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
It is recommended to fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Notice in wp-content/plugins/cellarweb-privacy-and-security-options/cellarweb-privacy-and-security.php+819
    Trying to access array offset on value of type bool

Server metrics [RAM: ▼1.58MB] [CPU: ▼57.15ms] Passed 4 tests

A check of server-side resources used by CellarWeb Privacy and Security Options
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.42 ▼1.057.06 ▼33.87
Dashboard /wp-admin2.44 ▼0.918.27 ▼57.31
Posts /wp-admin/edit.php2.44 ▼0.928.36 ▼41.11
Add New Post /wp-admin/post-new.php2.44 ▼3.457.61 ▼96.32
Media Library /wp-admin/upload.php2.44 ▼0.798.61 ▼24.52
Privacy and Security by CellarWeb /wp-admin/options-general.php?page=cellarweb_privacy_and_security2.447.96

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for CellarWeb Privacy and Security Options
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,817 ▲7014.32 ▼0.031.73 ▲0.0743.11 ▼2.00
Dashboard /wp-admin2,198 ▲275.58 ▲0.0790.35 ▼7.4235.16 ▼5.70
Posts /wp-admin/edit.php2,103 ▲31.94 ▼0.0338.97 ▼2.5331.01 ▼5.45
Add New Post /wp-admin/post-new.php1,525 ▼1023.44 ▼1.61593.09 ▼18.5157.40 ▼17.28
Media Library /wp-admin/upload.php1,397 ▼64.18 ▼0.0494.84 ▼7.0740.20 ▼2.06
Privacy and Security by CellarWeb /wp-admin/options-general.php?page=cellarweb_privacy_and_security1,3452.0024.5062.97

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/cellarweb-privacy-and-security-options/cellarweb-privacy-and-security.php+819
    Trying to access array offset on value of type bool
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Please fix the following server-side errors
  • 21 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=cellarweb_privacy_and_security
    • > Notice in wp-content/plugins/cellarweb-privacy-and-security-options/cellarweb-privacy-and-security.php+517
    Trying to access array offset on value of type bool

SRP 0% 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
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/cellarweb-privacy-and-security-options/css/custom_login_page.php
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_stylesheet_directory_uri() in wp-content/plugins/cellarweb-privacy-and-security-options/cellarweb-privacy-and-security.php:35

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 96% 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
1 plugin tags: site security privacy safety hardening

cellarweb-privacy-and-security-options/cellarweb-privacy-and-security.php 92% from 13 tests

The main PHP file in "CellarWeb Privacy and Security Options" ver. 4.14 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("cellarweb-privacy-and-security-options.php" instead of "cellarweb-privacy-and-security.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin1,218 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP3261405991
CSS3236207
XML20012
SVG1008

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.24
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%
Functions61
▷ Named functions5996.72%
▷ Anonymous functions23.28%
Constants7
▷ Global constants7100.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
6 PNG files occupy 0.13MB with 0.04MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
css/soda-cup-straw.png121.76KB58.15KB▼ 52.24%
css/warning-yellow.png0.95KB0.77KB▼ 19.47%
assets/curl-result.png4.43KB2.02KB▼ 54.31%
css/icons8-lock-30.png0.41KB0.35KB▼ 14.80%
css/icons8-high-importance-48.png0.95KB0.64KB▼ 32.65%