84% secure-content

Code Review | Secure Content

WordPress plugin Secure Content scored 84% from 54 tests.

About plugin

  • Plugin page: secure-content
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.4
  • WordPress version: 6.3.1
  • First release: Sep 19, 2014
  • Latest release: Jan 5, 2016
  • Number of updates: 5
  • Update frequency: every 94.8 days
  • Top authors: ajanthr (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active / 1,753 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.00MB] [CPU: ▼3.48ms] Passed 4 tests

An overview of server-side resources used by Secure Content
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0140.60 ▼5.93
Dashboard /wp-admin3.31 ▲0.0145.12 ▼5.78
Posts /wp-admin/edit.php3.36 ▲0.0047.73 ▼3.08
Add New Post /wp-admin/post-new.php5.89 ▲0.0094.34 ▲2.02
Media Library /wp-admin/upload.php3.23 ▲0.0035.04 ▲0.89

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Secure Content
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,949 ▲17814.67 ▼0.0123.91 ▲21.7341.98 ▼0.31
Dashboard /wp-admin2,206 ▲214.90 ▲0.00149.29 ▲30.6660.02 ▲16.67
Posts /wp-admin/edit.php2,092 ▲32.16 ▲0.1441.59 ▲1.4436.85 ▲0.28
Add New Post /wp-admin/post-new.php1,539 ▲623.13 ▼0.10687.12 ▲7.8353.86 ▼0.83
Media Library /wp-admin/upload.php1,391 ▲34.20 ▼0.0499.84 ▼14.3644.02 ▼1.86

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 were found after uninstall: 6 options
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

SRP 50% 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
Please fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/secure-content/securecontent.php:18

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
6 plugin tags: secure images, secure content, disable copying, security, image security...

secure-content/securecontent.php 85% from 13 tests

This is the main PHP file of "Secure Content" version 1.0.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please take the time to fix the following:
  • Description: The description should be shorter than 140 characters (currently 204 characters long)
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("secure-content.php" instead of "securecontent.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin22 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP15816
JavaScript1006

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.25
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%
Functions2
▷ Named functions2100.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