84% blaze-demo-importer

Code Review | Blaze Demo Importer

WordPress plugin Blaze Demo Importer scored84%from 54 tests.

About plugin

  • Plugin page: blaze-demo-importer
  • Plugin version: 1.0.4
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.3-6.3.2
  • WordPress version: 6.3.1
  • First release: Sep 24, 2022
  • Latest release: Nov 3, 2023
  • Number of updates: 6
  • Update frequency: every 67.7 days
  • Top authors: blazethemes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

9,000+ active /44,868 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼2.48ms] Passed 4 tests

Analyzing server-side resources used by Blaze Demo Importer
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0036.40 ▼1.48
Dashboard /wp-admin3.31 ▲0.0146.10 ▲3.25
Posts /wp-admin/edit.php3.42 ▲0.0743.64 ▼6.20
Add New Post /wp-admin/post-new.php5.89 ▲0.0089.78 ▼1.70
Media Library /wp-admin/upload.php3.23 ▲0.0032.69 ▼0.52

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 16 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by Blaze Demo Importer
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.25 ▼0.111.76 ▲0.0937.68 ▼4.98
Dashboard /wp-admin2,198 ▲315.61 ▼0.0584.36 ▼16.2042.85 ▲5.73
Posts /wp-admin/edit.php2,103 ▲61.98 ▼0.0234.51 ▼5.0133.42 ▼5.09
Add New Post /wp-admin/post-new.php1,535 ▲918.24 ▼5.38599.84 ▼17.9770.27 ▲28.05
Media Library /wp-admin/upload.php1,403 ▼04.23 ▼0.0096.49 ▼5.4643.56 ▼1.31

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 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)
Even though everything seems fine, this is not an exhaustive test

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
Almost there! Just fix the following items
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Customize_Setting' not found in wp-content/plugins/blaze-demo-importer/classes/class-customizer-option.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Importer' not found in wp-content/plugins/blaze-demo-importer/wordpress-importer/class-wp-import.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
7 plugin tags: one click import, import, blazethemes, demo importer, widgets...

blaze-demo-importer/blaze-demo-importer.php Passed 13 tests

The main PHP script in "Blaze Demo Importer" version 1.0.4 is automatically included on every request by WordPress
40 characters long description:
Easily imports demo with just one click.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin2,953 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP125926072,555
CSS1353210
JavaScript174188

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity52.00
▷ Minimum class complexity1.00
▷ Maximum class complexity214.00
Average method complexity6.19
▷ Minimum method complexity1.00
▷ Maximum method complexity50.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes10
▷ Abstract classes00.00%
▷ Concrete classes10100.00%
▷ Final classes220.00%
Methods97
▷ Static methods1414.43%
▷ Public methods8991.75%
▷ Protected methods33.09%
▷ Private methods55.15%
Functions6
▷ Named functions466.67%
▷ Anonymous functions233.33%
Constants8
▷ Global constants8100.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
There were not PNG files found in your plugin