84% encute

Code Review | Encute

WordPress plugin Encute scored84%from 54 tests.

About plugin

  • Plugin page: encute
  • Plugin version: 0.8.8
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.8-5.8.1
  • WordPress version: 6.3.1
  • First release: Oct 26, 2021
  • Latest release: Feb 17, 2022
  • Number of updates: 11
  • Update frequency: every 10.4 days
  • Top authors: markjaquith (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /4,590 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.75MB] [CPU: ▼2.61ms] Passed 4 tests

This is a short check of server-side resources used by Encute
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /4.23 ▲0.7744.08 ▲3.46
Dashboard /wp-admin4.06 ▲0.7255.88 ▼11.49
Posts /wp-admin/edit.php4.18 ▲0.8257.28 ▲6.29
Add New Post /wp-admin/post-new.php6.65 ▲0.7697.14 ▼8.69
Media Library /wp-admin/upload.php3.99 ▲0.7649.30 ▲11.38
Encute /wp-admin/tools.php?page=encute3.9635.71

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 90 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

Encute: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.28 ▲0.052.20 ▲0.5446.79 ▲5.65
Dashboard /wp-admin2,199 ▲215.58 ▼0.0785.79 ▼17.3944.35 ▲3.21
Posts /wp-admin/edit.php2,107 ▲72.08 ▲0.0741.99 ▲3.9637.59 ▼0.40
Add New Post /wp-admin/post-new.php1,548 ▲2223.47 ▲6.00617.23 ▼70.2951.00 ▼2.78
Media Library /wp-admin/upload.php1,398 ▼24.27 ▲0.0896.57 ▼20.3439.64 ▼9.01
Encute /wp-admin/tools.php?page=encute9371.9928.1537.21

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
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded

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
  • 41× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'CWS\\Encute\\Actions\\Action' not found in wp-content/plugins/encute/app/Actions/RemoveScript.php:5
    • > PHP Fatal error
      Uncaught Error: Interface 'CWS\\Encute\\Illuminate\\Contracts\\Support\\Arrayable' not found in wp-content/plugins/encute/lib/Tekta/Contracts/PluginData.php:16
    • > PHP Fatal error
      Uncaught Error: Class 'CWS\\Encute\\Actions\\Action' not found in wp-content/plugins/encute/app/Actions/RemoveStyleIf.php:7
    • > PHP Fatal error
      Uncaught Error: Interface 'CWS\\Encute\\Contracts\\Enqueueable' not found in wp-content/plugins/encute/app/Contracts/EnqueueableStyle.php:5
    • > PHP Fatal error
      Uncaught Error: Interface 'CWS\\Encute\\Illuminate\\Contracts\\Container\\ContextualBindingBuilder' not found in wp-content/plugins/encute/lib/Illuminate/Container/ContextualBindingBuilder.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'CWS\\Encute\\Illuminate\\Support\\ServiceProvider' not found in wp-content/plugins/encute/app/Providers/ActionsProvider.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'CWS\\Encute\\Actions\\ModifyStyleTag' not found in wp-content/plugins/encute/app/Actions/MakeStyleDefer.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'CWS\\Encute\\Enqueue' not found in wp-content/plugins/encute/app/Script.php:7
    • > PHP Fatal error
      Uncaught Error: Interface 'CWS\\Encute\\Illuminate\\Contracts\\Container\\Container' not found in wp-content/plugins/encute/lib/Illuminate/Container/Container.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'CWS\\Encute\\Actions\\Action' not found in wp-content/plugins/encute/app/Actions/MoveStyleToFooter.php:5

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)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
3 plugin tags: performance, scripts, styles

encute/index.php 85% from 13 tests

The entry point to "Encute" version 0.8.8 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("encute.php" instead of "index.php")
  • Domain Path: The domain path folder was not found ("/languages")

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
No dangerous file extensions were detected3,912 lines of code in 83 files:
LanguageFilesBlank linesComment linesLines of code
PHP771,2193,4363,794
JSON20075
YAML20041
CSS1001
JavaScript1001

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity8.94
▷ Minimum class complexity1.00
▷ Maximum class complexity92.00
Average method complexity2.09
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces18
Interfaces14
Traits2
Classes47
▷ Abstract classes612.77%
▷ Concrete classes4187.23%
▷ Final classes00.00%
Methods513
▷ Static methods10720.86%
▷ Public methods45488.50%
▷ Protected methods5610.92%
▷ Private methods30.58%
Functions51
▷ Named functions35.88%
▷ Anonymous functions4894.12%
Constants0
▷ Global constants00.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
No PNG images were found in this plugin