88% e-boekhoudennl-connector

Code Review | e-Boekhouden.nl

WordPress plugin e-Boekhouden.nl scored 88% from 54 tests.

About plugin

  • Plugin page: e-boekhoudennl-co...
  • Plugin version: 1.9.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.1
  • WordPress version: 5.8.1
  • First release: Sep 6, 2016
  • Latest release: Sep 6, 2016
  • Number of updates: 9
  • Update frequency: every 1.2 days
  • Top authors: eboekhouden (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

400+ active / 3,745 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.22MB] [CPU: ▼143.31ms] Passed 4 tests

Server-side resources used by e-Boekhouden.nl
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.01 ▲0.1725.04 ▲4.58
Dashboard /wp-admin3.34 ▲0.2832.01 ▼3.83
Posts /wp-admin/edit.php3.39 ▲0.2833.24 ▲3.38
Add New Post /wp-admin/post-new.php5.64 ▲0.2067.78 ▼575.86
Media Library /wp-admin/upload.php3.22 ▲0.2225.37 ▲3.09
Settings /wp-admin/admin.php?page=e-boekhoudennl-connector/eboekhouden-settings.php/settings3.1720.51
Orders /wp-admin/admin.php?page=e-boekhoudennl-connector/eboekhouden.php/orders3.2021.75
Products /wp-admin/admin.php?page=e-boekhoudennl-connector/eboekhouden.php/products3.1819.76

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 12 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for e-Boekhouden.nl
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,715 ▲11315.60 ▼0.076.61 ▲1.6676.06 ▲0.26
Dashboard /wp-admin2,969 ▲736.27 ▲0.15113.32 ▼17.24166.48 ▼8.99
Posts /wp-admin/edit.php2,779 ▲363.24 ▼0.1265.00 ▲1.44136.87 ▼6.62
Add New Post /wp-admin/post-new.php3,768 ▲2319.11 ▲0.51417.73 ▼30.45160.61 ▼4.53
Media Library /wp-admin/upload.php1,791 ▲365.52 ▼0.02145.15 ▲3.76181.06 ▼7.31
Settings /wp-admin/admin.php?page=e-boekhoudennl-connector/eboekhouden-settings.php/settings1,2282.3654.08126.69
Orders /wp-admin/admin.php?page=e-boekhoudennl-connector/eboekhouden.php/orders1,2932.4254.4699.47
Products /wp-admin/admin.php?page=e-boekhoudennl-connector/eboekhouden.php/products1,2492.3655.15102.55

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
This plugin's uninstaller ran successfully

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
These errors were triggered by the plugin
  • 12 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=e-boekhoudennl-connector/eboekhouden-settings.php/settings
    • > Notice in wp-content/plugins/e-boekhoudennl-connector/includes/eboekhouden.class.php+134
    Trying to access array offset on value of type bool
    • > GET request to /wp-admin/admin.php?page=e-boekhoudennl-connector/eboekhouden.php/products
    • > Notice in wp-content/plugins/e-boekhoudennl-connector/includes/lists/eboekhouden-product-list-table.php+230
    Undefined variable: products
    • > GET request to /wp-admin/admin.php?page=e-boekhoudennl-connector/eboekhouden.php/products
    • > Warning in wp-content/plugins/e-boekhoudennl-connector/includes/lists/eboekhouden-product-list-table.php+232
    usort() expects parameter 1 to be array, null given

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
  • 20× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/e-boekhoudennl-connector/includes/lists/eboekhouden-order-list-table.php on line 4
    • > PHP Notice
      Constant EBOEKHOUDEN_SUBMENU_CATEGORIES already defined in wp-content/plugins/e-boekhoudennl-connector/includes/defines.php on line 70
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/e-boekhoudennl-connector/includes/lists/eboekhouden-product-list-table.php on line 4
    • > PHP Notice
      Constant EBOEKHOUDEN_CONFIG_PASS_SETTING_LABEL already defined in wp-content/plugins/e-boekhoudennl-connector/includes/defines.php on line 22
    • > PHP Notice
      Constant EBOEKHOUDEN_CONFIGURATION already defined in wp-content/plugins/e-boekhoudennl-connector/includes/defines.php on line 66
    • > PHP Notice
      Constant EBOEKHOUDEN_CONFIG_ACCOUNT_SETTING_DESC already defined in wp-content/plugins/e-boekhoudennl-connector/includes/defines.php on line 19
    • > PHP Notice
      Constant EBOEKHOUDEN_CONFIG_ACCOUNT_SETTING_LABEL already defined in wp-content/plugins/e-boekhoudennl-connector/includes/defines.php on line 18
    • > PHP Notice
      Constant EBOEKHOUDEN_CONFIG_USERNAME_SETTING_LABEL already defined in wp-content/plugins/e-boekhoudennl-connector/includes/defines.php on line 20
    • > PHP Notice
      Constant EBOEKHOUDEN_SUBMENU_ORDERS already defined in wp-content/plugins/e-boekhoudennl-connector/includes/defines.php on line 68
    • > PHP Notice
      Constant EBOEKHOUDEN_CONFIG_USERNAME_SETTING_DESC already defined in wp-content/plugins/e-boekhoudennl-connector/includes/defines.php on line 21

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 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that need to be fixed:
  • Tags: Please reduce the number of tags, currently 28 tag instead of maximum 10
You can take inspiration from this readme.txt

e-boekhoudennl-connector/eboekhouden.php 92% from 13 tests

"e-Boekhouden.nl" version 1.9.3's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("e-boekhoudennl-connector.php" instead of "eboekhouden.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin1,292 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP83923151,292

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity23.83
▷ Minimum class complexity10.00
▷ Maximum class complexity38.00
Average method complexity2.69
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods81
▷ Static methods911.11%
▷ Public methods7592.59%
▷ Protected methods67.41%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants96
▷ Global constants96100.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
PNG images were not found in this plugin