88% advanced-import

Code Review | Advanced Import : One Click Import for WordPress or Theme Demo Data

WordPress plugin Advanced Import : One Click Import for WordPress or Theme Demo Data scored 88% from 54 tests.

About plugin

  • Plugin page: advanced-import
  • Plugin version: 1.3.5
  • PHP compatiblity: 5.6.20+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.9
  • WordPress version: 5.9.2
  • First release: Sep 26, 2019
  • Latest release: Feb 4, 2022
  • Number of updates: 29
  • Update frequency: every 29.8 days
  • Top authors: addonspress (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

70,000+ active / 507,955 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.03MB] [CPU: ▼295.83ms] Passed 4 tests

This is a short check of server-side resources used by Advanced Import : One Click Import for WordPress or Theme Demo Data
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.63 ▲0.1153.99 ▼8.39
Dashboard /wp-admin3.46 ▲0.0634.49 ▼8.32
Posts /wp-admin/edit.php3.69 ▲0.0552.64 ▲10.71
Add New Post /wp-admin/post-new.php6.93 ▼0.0493.87 ▼1,161.46
Media Library /wp-admin/upload.php3.35 ▲0.0624.37 ▼5.15
Advanced Import /wp-admin/tools.php?page=advanced-import-tool3.3635.47
Demo Import /wp-admin/themes.php?page=advanced-import3.3628.06

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 26 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by Advanced Import : One Click Import for WordPress or Theme Demo Data
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,773 ▲5115.32 ▼0.705.46 ▼0.442.01 ▼0.36
Dashboard /wp-admin2,898 ▲476.12 ▼0.01118.86 ▼17.41152.88 ▼42.13
Posts /wp-admin/edit.php2,701 ▲73.24 ▲0.0087.00 ▲20.76147.56 ▼3.94
Add New Post /wp-admin/post-new.php1,696 ▲3521.26 ▲5.59444.82 ▼5.83177.72 ▲15.24
Media Library /wp-admin/upload.php1,708 ▲75.53 ▼0.06153.42 ▼8.98195.63 ▼12.19
Advanced Import /wp-admin/tools.php?page=advanced-import-tool1,5025.2777.09127.05
Demo Import /wp-admin/themes.php?page=advanced-import1,5075.0377.81128.00

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
This plugin's uninstaller ran successfully

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/advanced-import/advanced-import.php
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/advanced-import/example.php:83

User-side errors Passed 1 test

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

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
6 plugin tags: demo import, theme import, widget import, advanced import, import...

advanced-import/advanced-import.php Passed 13 tests

"Advanced Import : One Click Import for WordPress or Theme Demo Data" version 1.3.5's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
71 characters long description:
Easily import demo data starter site packages or Migrate your site data

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected4,495 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
PHP164691,1242,420
JavaScript45072262,074
CSS1001

PHP code 50% from 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
It is recommended to fix the following
  • Please reduce cyclomatic complexity of methods to less than 100 (currently 112)
Cyclomatic complexity
Average complexity per logical line of code0.54
Average class complexity43.00
▷ Minimum class complexity1.00
▷ Maximum class complexity390.00
Average method complexity6.92
▷ Minimum method complexity1.00
▷ Maximum method complexity112.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes11
▷ Abstract classes00.00%
▷ Concrete classes11100.00%
▷ Final classes00.00%
Methods78
▷ Static methods810.26%
▷ Public methods6178.21%
▷ Protected methods00.00%
▷ Private methods1721.79%
Functions14
▷ Named functions14100.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants8100.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 are no PNG files in this plugin