74% import-shopify-to-wp

Code Review | Import Shopify To WP

WordPress plugin Import Shopify To WP scored74%from 54 tests.

About plugin

  • Plugin page: import-shopify-to-wp
  • Plugin version: 1.0.1
  • PHP compatiblity: 7.1+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6-5.8
  • WordPress version: 6.3.1
  • First release: Aug 1, 2021
  • Latest release: Mar 21, 2022
  • Number of updates: 6
  • Update frequency: every 39.0 days
  • Top authors: WPbeginner (66.67%)_smartik_ (33.33%)peterwilsoncc (33.33%)

Code review

54 tests

User reviews

2 reviews

Install metrics

400+ active /6,487 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.17MB] [CPU: ▼5.66ms] Passed 4 tests

Analyzing server-side resources used by Import Shopify To WP
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.64 ▲0.1836.69 ▼5.95
Dashboard /wp-admin3.48 ▲0.1346.12 ▼12.67
Posts /wp-admin/edit.php3.59 ▲0.2350.32 ▲5.51
Add New Post /wp-admin/post-new.php6.08 ▲0.1982.32 ▼7.90
Media Library /wp-admin/upload.php3.40 ▲0.1736.92 ▲3.90
Shopify Importer /wp-admin/tools.php?page=import-shopify-to-wp3.4335.05

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 55 new files
Database: 1 new table, 6 new options
New tables
wp_shopify2wp_variations_log
New WordPress options
widget_recent-comments
db_upgraded
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Import Shopify To WP
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,848 ▲10214.73 ▲0.091.86 ▲0.0639.96 ▼10.82
Dashboard /wp-admin2,226 ▲385.78 ▲0.9098.10 ▼23.6541.77 ▼1.07
Posts /wp-admin/edit.php2,112 ▲232.05 ▲0.0137.29 ▲0.3233.31 ▼1.19
Add New Post /wp-admin/post-new.php1,549 ▲2123.11 ▲4.83676.94 ▲48.1268.02 ▲18.90
Media Library /wp-admin/upload.php1,405 ▲204.22 ▲0.0896.66 ▼9.0043.26 ▼1.90
Shopify Importer /wp-admin/tools.php?page=import-shopify-to-wp9038.44177.8927.10

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • The plugin did not uninstall successfully, leaving 1 table in the database
    • wp_shopify2wp_variations_log
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options

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)
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 items
  • 11× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/import-shopify-to-wp/import-shopify-to-wp.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'S2WPImporter\\Process\\AbstractRecord' not found in wp-content/plugins/import-shopify-to-wp/app/Process/Order.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'S2WPImporter\\Process\\AbstractRecord' not found in wp-content/plugins/import-shopify-to-wp/app/Process/Customer.php:7
    • > PHP Fatal error
      Trait 'S2WPImporter\\Traits\\ErrorTrait' not found in wp-content/plugins/import-shopify-to-wp/app/Process/AbstractRecord.php on line 7
    • > PHP Fatal error
      Trait 'S2WPImporter\\Traits\\ErrorTrait' not found in wp-content/plugins/import-shopify-to-wp/app/IdMapping.php on line 7
    • > PHP Fatal error
      Trait 'S2WPImporter\\Traits\\AjaxTrait' not found in wp-content/plugins/import-shopify-to-wp/app/Plugins/Installer.php on line 12
    • > PHP Fatal error
      Trait 'S2WPImporter\\Traits\\ErrorTrait' not found in wp-content/plugins/import-shopify-to-wp/app/Image.php on line 8
    • > PHP Fatal error
      Uncaught Error: Class 'S2WPImporter\\AbstractDB' not found in wp-content/plugins/import-shopify-to-wp/app/VariationsLog.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Upgrader_Skin' not found in wp-content/plugins/import-shopify-to-wp/app/Plugins/UpgraderSkin.php:10
    • > PHP Fatal error
      Trait 'S2WPImporter\\Traits\\AjaxTrait' not found in wp-content/plugins/import-shopify-to-wp/app/Process/Importer.php on line 8

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

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
5 plugin tags: import, free, woocommerce, export, shopify

import-shopify-to-wp/import-shopify-to-wp.php Passed 13 tests

The entry point to "Import Shopify To WP" version 1.0.1 is a PHP file that has certain tags in its header comment area
49 characters long description:
Easily transfer your Shopify Store to WooCommerce

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected3,440 lines of code in 53 files:
LanguageFilesBlank linesComment linesLines of code
PHP356911,1202,120
TypeScript1116237893
Sass15819337
SVG20282
JSON1005
JavaScript2002
CSS1001

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity10.58
▷ Minimum class complexity1.00
▷ Maximum class complexity58.00
Average method complexity2.54
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces6
Interfaces1
Traits2
Classes23
▷ Abstract classes28.70%
▷ Concrete classes2191.30%
▷ Final classes00.00%
Methods165
▷ Static methods169.70%
▷ Public methods14587.88%
▷ Protected methods1810.91%
▷ Private methods21.21%
Functions14
▷ Named functions17.14%
▷ Anonymous functions1392.86%
Constants5
▷ Global constants360.00%
▷ Class constants240.00%
▷ Public constants2100.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
No PNG files were detected