83% xl-logo-carousel

Code Review | XL Logo Carousel

WordPress plugin XL Logo Carousel scored83%from 54 tests.

About plugin

  • Plugin page: xl-logo-carousel
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2-4.9.4
  • WordPress version: 6.3.1
  • First release: Dec 15, 2015
  • Latest release: Mar 10, 2018
  • Number of updates: 6
  • Update frequency: every 136.0 days
  • Top authors: xltheme (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /3,031 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

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

This is a short check of server-side resources used by XL Logo Carousel
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0444.38 ▲2.64
Dashboard /wp-admin3.33 ▲0.0346.19 ▼3.47
Posts /wp-admin/edit.php3.38 ▲0.0351.12 ▲4.75
Add New Post /wp-admin/post-new.php5.91 ▲0.0392.34 ▼3.61
Media Library /wp-admin/upload.php3.26 ▲0.0338.48 ▲1.02
Add New /wp-admin/post-new.php?post_type=logo3.3146.77
All Logos /wp-admin/edit.php?post_type=logo3.3034.83

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

XL Logo Carousel: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,925 ▲15413.78 ▼0.605.11 ▲2.9937.45 ▼6.95
Dashboard /wp-admin2,230 ▲425.83 ▼0.07105.11 ▼11.5741.51 ▼1.92
Posts /wp-admin/edit.php2,119 ▲302.05 ▲0.0442.95 ▲5.7037.62 ▲3.96
Add New Post /wp-admin/post-new.php1,556 ▲2622.98 ▲4.73642.99 ▲26.4156.64 ▼4.00
Media Library /wp-admin/upload.php1,418 ▲274.21 ▼0.0498.92 ▼3.6342.45 ▼0.17
Add New /wp-admin/post-new.php?post_type=logo1,6153.7263.7035.91
All Logos /wp-admin/edit.php?post_type=logo1,0892.0830.3529.19

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% 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
Almost there! Just fix the following items
  • 4× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/xl-logo-carousel/public/xl-logo-view.php:42
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/xl-logo-carousel/lib/xl-logo-scripts.php:18
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/xl-logo-carousel/lib/xl-logo-cpt.php:30
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/xl-logo-carousel/lib/xl-logo-scripts.php:18

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that need to be fixed:
  • Tags: There are too many tags (13 tag instead of maximum 10)
Please take inspiration from this readme.txt

xl-logo-carousel/xl-logo.php 85% from 13 tests

This is the main PHP file of "XL Logo Carousel" version 1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("xl-logo-carousel.php" instead of "xl-logo.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 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected2,087 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript34508571,791
CSS2924221
PHP4191875

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.11
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected