84% operation-demo-importer

Code Review | Operation Demo Importer – Demo Importer For WPoperation Themes

WordPress plugin Operation Demo Importer – Demo Importer For WPoperation Themes scored84%from 54 tests.

About plugin

  • Plugin page: operation-demo-im...
  • Plugin version: 1.1.9
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5.0-6.1
  • WordPress version: 6.3.1
  • First release: Aug 30, 2018
  • Latest release: Nov 7, 2022
  • Number of updates: 26
  • Update frequency: every 58.9 days
  • Top authors: wpoperations (100%)

Code review

54 tests

User reviews

1 review

Install metrics

3,000+ active /70,906 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.01MB] [CPU: ▼0.97ms] Passed 4 tests

This is a short check of server-side resources used by Operation Demo Importer – Demo Importer For WPoperation Themes
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0137.84 ▼4.73
Dashboard /wp-admin3.31 ▲0.0152.07 ▲1.61
Posts /wp-admin/edit.php3.36 ▲0.0049.41 ▲3.36
Add New Post /wp-admin/post-new.php5.89 ▲0.0094.03 ▼2.14
Media Library /wp-admin/upload.php3.23 ▲0.0036.45 ▲1.39

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 18 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
operation-demo-importer-version
db_upgraded
widget_recent-posts
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Operation Demo Importer – Demo Importer For WPoperation Themes
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲9013.25 ▼1.154.96 ▲3.1940.83 ▼3.93
Dashboard /wp-admin2,206 ▲205.81 ▲0.8296.42 ▼21.7039.09 ▼6.39
Posts /wp-admin/edit.php2,089 ▼02.05 ▲0.0441.79 ▲6.8836.28 ▲2.27
Add New Post /wp-admin/post-new.php1,528 ▼618.10 ▼4.88635.58 ▼38.7356.59 ▲3.50
Media Library /wp-admin/upload.php1,391 ▲34.24 ▼0.0198.86 ▼16.2542.68 ▼3.11

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 7 options
    • operation-demo-importer-version
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

SRP 50% 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 fix the following
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-includes/class-wp-customize-setting.php' (include_path='.:/usr/share/php') in wp-content/plugins/operation-demo-importer/classes/importers/class-settings-importer.php on line 95
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/operation-demo-importer/classes/importers/class-settings-importer.php on line 95
    • > PHP Warning
      require_once(ABSPATHwp-includes/class-wp-customize-setting.php): failed to open stream: No such file or directory in wp-content/plugins/operation-demo-importer/classes/importers/class-settings-importer.php on line 95

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
3 plugin tags: wpoperation, importer, demo importer

operation-demo-importer/operation-demo-importer.php 92% from 13 tests

The entry point to "Operation Demo Importer – Demo Importer For WPoperation Themes" version 1.1.9 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

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
There were no executable files found in this plugin3,411 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP106878412,495
CSS2923578
JavaScript213465338

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity36.21
▷ 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
Classes14
▷ Abstract classes00.00%
▷ Concrete classes14100.00%
▷ Final classes214.29%
Methods95
▷ Static methods1212.63%
▷ Public methods8589.47%
▷ Protected methods33.16%
▷ Private methods77.37%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants7
▷ Global constants7100.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