68% canvasflow-export

Code Review | Canvasflow Export

WordPress plugin Canvasflow Export scored68%from 54 tests.

About plugin

  • Plugin page: canvasflow-export
  • Plugin version: 1.2.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.2-5.4.1
  • WordPress version: 6.3.1
  • First release: Mar 26, 2019
  • Latest release: May 12, 2020
  • Number of updates: 13
  • Update frequency: every 32.1 days
  • Top authors: canvasflow (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /598 total downloads

Benchmarks

Plugin footprint 65% 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.94MB] [CPU: ▼29.90ms] Passed 4 tests

Analyzing server-side resources used by Canvasflow Export
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0142.19 ▲6.89
Dashboard /wp-admin3.00 ▼0.3023.20 ▼25.22
Posts /wp-admin/edit.php3.00 ▼0.3624.41 ▼20.35
Add New Post /wp-admin/post-new.php3.00 ▼2.8924.18 ▼62.74
Media Library /wp-admin/upload.php3.00 ▼0.2322.45 ▼11.27
Canvasflow Export /wp-admin/options-general.php?page=canvasflow-export-rest3.0023.27

Server storage [IO: ▲0.05MB] [DB: ▲0.07MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 10 new files
Database: 1 new table, 6 new options
New tables
wp_canvasflow_rest_credentials
New WordPress options
widget_recent-posts
widget_recent-comments
can_compress_scripts
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Canvasflow Export
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,808 ▲5113.17 ▼1.411.76 ▼0.1543.83 ▼2.14
Dashboard /wp-admin2,211 ▲195.83 ▲0.9098.10 ▼15.7141.97 ▼2.81
Posts /wp-admin/edit.php2,100 ▲112.04 ▼0.0135.14 ▼0.3631.19 ▼2.15
Add New Post /wp-admin/post-new.php1,521 ▼1223.12 ▲0.09696.09 ▲26.3756.88 ▼11.54
Media Library /wp-admin/upload.php1,390 ▲84.20 ▼0.0296.60 ▼4.9940.61 ▼5.16
Canvasflow Export /wp-admin/options-general.php?page=canvasflow-export-rest8502.0624.6644.40

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • This plugin cannot be uninstalled
    • > User notice in wp-includes/functions.php+5905
    Function add_submenu_page was called incorrectly. The seventh parameter passed to add_submenu_page() should be numeric representing menu position. Please see Debugging in WordPress for more information. (This message was added in version 5.3.0.)
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Smoke test failed, please fix the following
    • > GET request to /wp-admin/options-general.php?page=canvasflow-export-rest
    • > User notice in wp-includes/functions.php+5905
    Function add_submenu_page was called incorrectly. The seventh parameter passed to add_submenu_page() should be numeric representing menu position. Please see Debugging in WordPress for more information. (This message was added in version 5.3.0.)

SRP 50% 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
The following issues need your attention
  • 4× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/canvasflow-export/canvasflow-export.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/canvasflow-export/includes/views/canvasflow-export-settings-view.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'WP_REST_Controller' not found in wp-content/plugins/canvasflow-export/includes/canvasflow-export-controller.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'Canvasflow_Export_DB' not found in wp-content/plugins/canvasflow-export/includes/canvasflow-export-settings.php:7

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 96% from 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
7 plugin tags: html5, digital publishing solution, html to wordpress, digital publishing, publish to wordpress...

canvasflow-export/canvasflow-export.php 92% from 13 tests

The main file in "Canvasflow Export" v. 1.2.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
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 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin1,148 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP5189120930
CSS1210130
Markdown126064
JavaScript13024

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity41.33
▷ Minimum class complexity5.00
▷ Maximum class complexity105.00
Average method complexity3.37
▷ Minimum method complexity1.00
▷ Maximum method complexity30.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods51
▷ Static methods00.00%
▷ Public methods3874.51%
▷ Protected methods00.00%
▷ Private methods1325.49%
Functions7
▷ Named functions685.71%
▷ Anonymous functions114.29%
Constants1
▷ Global constants1100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/img/favicon.png0.90KB0.57KB▼ 36.97%