84% wa-fronted

Code Review | WA Fronted

WordPress plugin WA Fronted scored84%from 54 tests.

About plugin

  • Plugin page: wa-fronted
  • Plugin version: 1.3.9
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.3.1
  • WordPress version: 6.3.1
  • First release: Nov 3, 2015
  • Latest release: Dec 1, 2015
  • Number of updates: 19
  • Update frequency: every 1.5 days
  • Top authors: jesperb (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /1,647 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼4.77ms] Passed 4 tests

This is a short check of server-side resources used by WA Fronted
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.62 ▲0.1634.42 ▼6.67
Dashboard /wp-admin3.33 ▲0.0344.70 ▼3.22
Posts /wp-admin/edit.php3.38 ▲0.0345.59 ▼0.95
Add New Post /wp-admin/post-new.php5.91 ▲0.0382.36 ▼8.25
Media Library /wp-admin/upload.php3.25 ▲0.0233.27 ▼0.89

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 505 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for WA Fronted
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲7913.32 ▼1.354.62 ▲2.9143.64 ▲4.28
Dashboard /wp-admin2,206 ▲184.83 ▼0.06107.57 ▲3.1837.80 ▼7.94
Posts /wp-admin/edit.php2,092 ▲31.99 ▼0.0538.61 ▲2.4233.31 ▼3.31
Add New Post /wp-admin/post-new.php1,514 ▼1917.60 ▼3.70626.62 ▼61.0052.44 ▼2.55
Media Library /wp-admin/upload.php1,391 ▼04.20 ▼0.0198.55 ▲1.9442.16 ▼5.65

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please take a closer look at the following
  • 4× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'Shortcode_UI' not found in wp-content/plugins/wa-fronted/extensions/shortcake/shortcake.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'WA_Fronted' not found in wp-content/plugins/wa-fronted/extensions/acf/acf.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'WA_Fronted' not found in wp-content/plugins/wa-fronted/extensions/woocommerce/woocommerce.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/wa-fronted/wa-fronted.php:32

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need to be fixed:
  • Screenshots: No descriptions were found for these screenshots #2, #3 in wa-fronted/assets to your readme.txt
Please take inspiration from this readme.txt

wa-fronted/wa-fronted.php Passed 13 tests

The main PHP script in "WA Fronted" version 1.3.9 is automatically included on every request by WordPress
63 characters long description:
Edit content directly from fronted in the contents actual place

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin66,700 lines of code in 368 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript25411,3626,79550,914
Sass37905396,113
HTML231,0041,6783,986
PHP43182711,840
SVG3221,096
CSS1482511,006
Markdown112300988
JSON1900524
LESS14211214
YAML24019

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.50
Average class complexity88.00
▷ Minimum class complexity1.00
▷ Maximum class complexity220.00
Average method complexity7.42
▷ Minimum method complexity1.00
▷ Maximum method complexity41.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods54
▷ Static methods11.85%
▷ Public methods4277.78%
▷ Protected methods1018.52%
▷ Private methods23.70%
Functions11
▷ Named functions218.18%
▷ Anonymous functions981.82%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
63 PNG files occupy 0.45MB with 0.23MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
bower_components/select2/docs/vendor/images/flags/or.png9.31KB4.06KB▼ 56.38%
bower_components/select2/docs/vendor/images/flags/ms.png5.95KB2.64KB▼ 55.60%
bower_components/select2/docs/vendor/images/flags/ri.png6.76KB3.13KB▼ 53.76%
bower_components/select2/docs/vendor/images/flags/ok.png7.12KB3.33KB▼ 53.22%
bower_components/select2/docs/vendor/images/flags/nm.png1.49KB0.96KB▼ 35.13%