78% akaunting-for-woocommerce

Code Review | Akaunting for WooCommerce

WordPress plugin Akaunting for WooCommerce scored78%from 54 tests.

About plugin

  • Plugin page: akaunting-for-woo...
  • Plugin version: 2.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.0
  • WordPress version: 6.3.1
  • First release: Dec 7, 2017
  • Latest release: Oct 13, 2022
  • Number of updates: 38
  • Update frequency: every 46.7 days
  • Top authors: akaunting (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /8,583 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.10MB] [CPU: ▼5.50ms] Passed 4 tests

A check of server-side resources used by Akaunting for WooCommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1045.50 ▲6.46
Dashboard /wp-admin3.41 ▲0.0747.04 ▼13.80
Posts /wp-admin/edit.php3.52 ▲0.1746.89 ▼0.45
Add New Post /wp-admin/post-new.php6.00 ▲0.1191.35 ▼9.83
Media Library /wp-admin/upload.php3.33 ▲0.1134.85 ▲2.10
Akaunting WooCommerce /wp-admin/options-general.php?page=akaunting-woocommerce3.3031.38

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Akaunting for WooCommerce
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲8314.74 ▲0.092.34 ▲0.5740.10 ▼3.33
Dashboard /wp-admin2,207 ▲155.88 ▲0.94107.63 ▲1.8239.81 ▼3.07
Posts /wp-admin/edit.php2,093 ▲12.05 ▲0.0539.87 ▲3.6235.44 ▲3.27
Add New Post /wp-admin/post-new.php1,540 ▲2623.21 ▲5.67628.76 ▼72.4553.25 ▲0.98
Media Library /wp-admin/upload.php1,386 ▲14.19 ▼0.0093.59 ▼16.6042.90 ▼1.85
Akaunting WooCommerce /wp-admin/options-general.php?page=akaunting-woocommerce7852.0323.8226.07

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check 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 | 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
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/akaunting-for-woocommerce/akaunting-woocommerce.php
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_fields() in wp-content/plugins/akaunting-for-woocommerce/options.php:4

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 Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
8 plugin tags: payments, invoices, billing, budget, bookkeeping...

akaunting-for-woocommerce/akaunting-woocommerce.php 85% from 13 tests

The primary PHP file in "Akaunting for WooCommerce" version 2.0.2 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("akaunting-for-woocommerce.php" instead of "akaunting-woocommerce.php")
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

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
Everything looks great! No dangerous files found in this plugin567 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP417753567

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity23.67
▷ Minimum class complexity6.00
▷ Maximum class complexity45.00
Average method complexity2.88
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods35
▷ Static methods12.86%
▷ Public methods2982.86%
▷ Protected methods617.14%
▷ Private methods00.00%
Functions2
▷ Named functions150.00%
▷ Anonymous functions150.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin