10% frontaccounting-connect

Code Review | Frontaccounting connect

WordPress plugin Frontaccounting connect scored10%from 54 tests.

About plugin

  • Plugin page: frontaccounting-c...
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.8.1
  • WordPress version: 6.3.1
  • First release: Aug 21, 2013
  • Latest release: Mar 7, 2014
  • Number of updates: 4
  • Update frequency: every 49.5 days
  • Top authors: dreaddymck (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /982 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
You still need to fix the following installer errors
  • The plugin did not install without errors
    • > Deprecated in wp-content/plugins/frontaccounting-connect/FACWidget.php+14
    Methods with the same name as their class will not be constructors in a future version of PHP; FACWidget has a deprecated constructor

Server metrics [RAM: ▼1.79MB] [CPU: ▼51.61ms] Passed 4 tests

An overview of server-side resources used by Frontaccounting connect
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.19 ▼1.275.99 ▼32.19
Dashboard /wp-admin2.21 ▼1.096.92 ▼40.25
Posts /wp-admin/edit.php2.21 ▼1.147.16 ▼38.28
Add New Post /wp-admin/post-new.php2.21 ▼3.676.74 ▼95.72
Media Library /wp-admin/upload.php2.21 ▼1.016.96 ▼30.59
FaC /wp-admin/options-general.php?page=fac_settings2.217.45

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 17 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by Frontaccounting connect
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,819 ▲7313.24 ▼1.154.35 ▲2.5641.65 ▲2.27
Dashboard /wp-admin2,183 ▼95.84 ▲0.9394.25 ▼13.7640.33 ▼1.69
Posts /wp-admin/edit.php2,081 ▼82.04 ▼0.0034.02 ▼2.5732.13 ▼0.28
Add New Post /wp-admin/post-new.php1,539 ▲2023.34 ▲0.06670.24 ▼9.4274.49 ▲21.67
Media Library /wp-admin/upload.php1,368 ▼234.23 ▲0.00100.13 ▼0.8540.02 ▼4.49
FaC /wp-admin/options-general.php?page=fac_settings9002.2931.9126.21

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Uninstall procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/frontaccounting-connect/FACWidget.php+14
    Methods with the same name as their class will not be constructors in a future version of PHP; FACWidget has a deprecated constructor
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=fac_settings
    • > Deprecated in wp-content/plugins/frontaccounting-connect/FACWidget.php+14
    Methods with the same name as their class will not be constructors in a future version of PHP; FACWidget has a deprecated constructor

SRP 0% 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
Please take a closer look at the following
  • 7× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/frontaccounting-connect/templates/fac-widget-content.php
    • > /wp-content/plugins/frontaccounting-connect/FACimage.php
    • > /wp-content/plugins/frontaccounting-connect/fac.php
    • > /wp-content/plugins/frontaccounting-connect/templates/fac-shortcode-content.php
    • > /wp-content/plugins/frontaccounting-connect/templates/fac-the-content.php
    • > /wp-content/plugins/frontaccounting-connect/FACImportPost.php
    • > /wp-content/plugins/frontaccounting-connect/FACAdminMeta.php
  • 8× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'FAConnectItems' not found in wp-content/plugins/frontaccounting-connect/FAConnectItemHtml.php:5
    • > PHP Notice
      Undefined variable: text_color in wp-content/plugins/frontaccounting-connect/FACimage.php on line 13
    • > PHP Warning
      imagecolordeallocate() expects exactly 2 parameters, 1 given in wp-content/plugins/frontaccounting-connect/FACimage.php on line 12
    • > PHP Warning
      imagecolordeallocate() expects exactly 2 parameters, 1 given in wp-content/plugins/frontaccounting-connect/FACimage.php on line 14
    • > PHP Notice
      Undefined variable: line_color in wp-content/plugins/frontaccounting-connect/FACimage.php on line 12
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/frontaccounting-connect/FACWidget.php:14
    • > PHP Warning
      imagecolordeallocate() expects exactly 2 parameters, 1 given in wp-content/plugins/frontaccounting-connect/FACimage.php on line 13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/frontaccounting-connect/FACAdminMenu.php:94

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 93% from 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
4 plugin tags: frontaccounting, erp, plugin, widget

frontaccounting-connect/fac.php 85% from 13 tests

"Frontaccounting connect" version 0.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("frontaccounting-connect.php" instead of "fac.php")
  • Description: The description should be shorter than 140 characters (currently 243 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected1,541 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP135513081,527
CSS121814

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity18.50
▷ Minimum class complexity1.00
▷ Maximum class complexity36.00
Average method complexity2.94
▷ Minimum method complexity1.00
▷ Maximum method complexity15.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods72
▷ Static methods00.00%
▷ Public methods72100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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