84% themegrill-demo-importer

Code Review | ThemeGrill Demo Importer

WordPress plugin ThemeGrill Demo Importer scored84%from 54 tests.

About plugin

  • Plugin page: themegrill-demo-i...
  • Plugin version: 1.9.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.3
  • WordPress version: 6.3.1
  • First release: Dec 5, 2016
  • Latest release: Aug 23, 2023
  • Number of updates: 68
  • Update frequency: every 36.0 days
  • Top authors: themegrilldev (54.41%)ThemeGrill (47.06%)

Code review

54 tests

User reviews

196 reviews

Install metrics

100,000+ active /4,559,321 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.06MB] [CPU: ▼1.63ms] Passed 4 tests

Server-side resources used by ThemeGrill Demo Importer
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0544.79 ▲3.23
Dashboard /wp-admin3.37 ▲0.0650.98 ▼2.12
Posts /wp-admin/edit.php3.48 ▲0.1253.32 ▼1.48
Add New Post /wp-admin/post-new.php5.95 ▲0.0699.95 ▼6.15
Media Library /wp-admin/upload.php3.29 ▲0.0642.98 ▲5.08

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 41 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for ThemeGrill Demo Importer
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,805 ▲4414.26 ▲0.041.64 ▼0.0540.04 ▼4.99
Dashboard /wp-admin2,208 ▲285.56 ▼0.0889.11 ▼5.4040.41 ▼4.46
Posts /wp-admin/edit.php2,119 ▲192.01 ▼0.0343.30 ▲5.6436.42 ▼0.48
Add New Post /wp-admin/post-new.php1,536 ▲1023.54 ▲0.44607.40 ▼69.5651.50 ▼12.80
Media Library /wp-admin/upload.php1,413 ▲134.18 ▼0.0998.94 ▼12.4944.32 ▼6.88

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Upgrader' not found in wp-content/plugins/themegrill-demo-importer/includes/admin/class-demo-pack-upgrader.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Customize_Setting' not found in wp-content/plugins/themegrill-demo-importer/includes/importers/customize/class-oc-customize-demo-importer-setting.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration Passed 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
5 plugin tags: importer, one click import, themegrill, demo, theme demos

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

The main PHP script in "ThemeGrill Demo Importer" version 1.9.4 is automatically included on every request by WordPress
95 characters long description:
Import ThemeGrill official themes demo content, widgets and theme settings 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
Good job! No executable or dangerous file extensions detected7,917 lines of code in 38 files:
LanguageFilesBlank linesComment linesLines of code
PHP228541,2414,119
JavaScript95204972,515
CSS5174181,002
Sass2510281

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity49.50
▷ Minimum class complexity1.00
▷ Maximum class complexity265.00
Average method complexity6.52
▷ Minimum method complexity1.00
▷ Maximum method complexity62.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes14
▷ Abstract classes00.00%
▷ Concrete classes14100.00%
▷ Final classes214.29%
Methods123
▷ Static methods1713.82%
▷ Public methods10887.80%
▷ Protected methods32.44%
▷ Private methods129.76%
Functions15
▷ Named functions15100.00%
▷ Anonymous functions00.00%
Constants9
▷ Global constants9100.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
No PNG images were found in this plugin