88% simple-csv-xls-exporter

Code Review | Simple CSV/XLS Exporter

WordPress plugin Simple CSV/XLS Exporter scored 88% from 54 tests.

About plugin

  • Plugin page: simple-csv-xls-ex...
  • Plugin version: 1.5.8
  • PHP version: 7.4.16
  • WordPress version: 5.8.1
  • First release: Feb 26, 2016
  • Latest release: Feb 1, 2022
  • Number of updates: 183
  • Update frequency: every 11.8 days
  • Top authors: Dukessa (65.57%)Shambix (34.97%)

Code review

54 tests

User reviews

19 reviews

Install metrics

6,000+ active / 77,258 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.09MB] [CPU: ▼145.80ms] Passed 4 tests

Server-side resources used by Simple CSV/XLS Exporter
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.93 ▲0.0932.58 ▲9.71
Dashboard /wp-admin3.17 ▲0.1031.60 ▼6.06
Posts /wp-admin/edit.php3.25 ▲0.1432.34 ▲2.37
Add New Post /wp-admin/post-new.php5.53 ▲0.0972.88 ▼580.37
Media Library /wp-admin/upload.php3.11 ▲0.1023.18 ▲0.88
CSV/XLS Export /wp-admin/tools.php?page=Simple_CSV_Exporter_Settings3.0827.20

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 19 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Simple CSV/XLS Exporter: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,688 ▲8615.73 ▼0.305.37 ▲0.4876.51 ▼1.99
Dashboard /wp-admin2,952 ▲566.15 ▼0.03124.14 ▼9.68169.31 ▼8.00
Posts /wp-admin/edit.php2,759 ▲193.27 ▲0.0563.99 ▼1.72134.67 ▼1.43
Add New Post /wp-admin/post-new.php2,507 ▼1,20715.90 ▼2.62416.80 ▼48.59158.30 ▼11.70
Media Library /wp-admin/upload.php1,774 ▲255.60 ▲0.06136.39 ▼0.74183.20 ▼4.84
CSV/XLS Export /wp-admin/tools.php?page=Simple_CSV_Exporter_Settings2,0112.6158.84217.79

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Please fix the following server-side errors
    • > GET request to /wp-admin/tools.php?page=Simple_CSV_Exporter_Settings
    • > Warning in wp-includes/formatting.php+2140
    strtolower() expects parameter 1 to be string, array given
  • 26 occurences, only the last one shown
    • > GET request to /wp-admin/tools.php?page=Simple_CSV_Exporter_Settings
    • > Notice in wp-content/plugins/simple-csv-xls-exporter/classes/simple-csv-exporter-settings.php+301
    Trying to access array offset on value of type bool

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_die() in wp-content/plugins/simple-csv-xls-exporter/process/simple_csv_xls_exporter_csv_xls.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Please fix the following attributes:
  • Requires at least: Version not formatted correctly
  • Screenshots: Add images for these screenshots: #1 (Settings Page), #2 (Settings Page), #3 (Settings Page)
The official readme.txt might help

simple-csv-xls-exporter/simple-csv-xls-exporter.php 92% from 13 tests

This is the main PHP file of "Simple CSV/XLS Exporter" version 1.5.8, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please take the time to fix the following:
  • Description: Keep the plugin description shorter than 140 characters (currently 210 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected930 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP8171274868
CSS114862

PHP code Passed 2 tests

A short 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.32
Average class complexity16.00
▷ Minimum class complexity4.00
▷ Maximum class complexity28.00
Average method complexity2.76
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods17
▷ Static methods211.76%
▷ Public methods17100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants7
▷ Global constants7100.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