84% optimize-wp-website

Code Review | Optimize Website – Load files where required.

WordPress plugin Optimize Website – Load files where required. scored84%from 54 tests.

About plugin

  • Plugin page: optimize-wp-website
  • Plugin version: 1.2
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6-6.3.1
  • WordPress version: 6.3.1
  • First release: Jun 5, 2020
  • Latest release: Sep 27, 2023
  • Number of updates: 16
  • Update frequency: every 75.6 days
  • Top authors: india-web-developer (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /754 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.06MB] [CPU: ▼7.81ms] Passed 4 tests

Server-side resources used by Optimize Website – Load files where required.
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0837.72 ▼1.50
Dashboard /wp-admin3.37 ▲0.0347.45 ▼13.34
Posts /wp-admin/edit.php3.49 ▲0.1344.70 ▼1.98
Add New Post /wp-admin/post-new.php5.95 ▲0.0785.11 ▼14.42
Media Library /wp-admin/upload.php3.30 ▲0.0741.89 ▲7.74
WP Optimize Site /wp-admin/options-general.php?page=wp_optimize_site3.2733.05

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Optimize Website – Load files where required.
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,818 ▲3214.35 ▲0.081.56 ▼0.2138.17 ▼0.94
Dashboard /wp-admin2,213 ▲325.62 ▼0.0984.12 ▼25.0939.13 ▲0.79
Posts /wp-admin/edit.php2,118 ▲152.02 ▲0.0234.51 ▼2.2137.59 ▲7.81
Add New Post /wp-admin/post-new.php1,546 ▲2018.45 ▼4.52605.00 ▼94.2693.51 ▼9.87
Media Library /wp-admin/upload.php1,412 ▲124.20 ▼0.0195.34 ▼11.8541.92 ▼3.22
WP Optimize Site /wp-admin/options-general.php?page=wp_optimize_site1,0132.0624.5944.38

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check 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
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_fields() in wp-content/plugins/optimize-wp-website/lib/settings.php:5

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
9 plugin tags: optimize website, site optimization, website speed, optimize wp, fast speed...

optimize-wp-website/optimize-wp-site.php 92% from 13 tests

"Optimize Website – Load files where required." version 1.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("optimize-wp-website.php" instead of "optimize-wp-site.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
Good job! No executable or dangerous file extensions detected345 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP327101333
JavaScript10111
CSS1001

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.52
Average class complexity49.00
▷ Minimum class complexity49.00
▷ Maximum class complexity49.00
Average method complexity3.53
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods19
▷ Static methods00.00%
▷ Public methods19100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin