10% seatgeek-tour-dates

Code Review | Tour Dates

WordPress plugin Tour Dates scored10%from 54 tests.

About plugin

  • Plugin page: seatgeek-tour-dates
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.8.1
  • WordPress version: 6.3.1
  • First release: Mar 10, 2014
  • Latest release: Mar 20, 2014
  • Number of updates: 8
  • Update frequency: every 3.8 days
  • Top authors: SeatGeek (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,275 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
It is recommended to fix the following installer errors
  • This plugin did not install gracefully
    • > Deprecated in wp-content/plugins/seatgeek-tour-dates/tour-dates.php+370
    Function create_function() is deprecated

Server metrics [RAM: ▼1.97MB] [CPU: ▼60.35ms] Passed 4 tests

A check of server-side resources used by Tour Dates
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.445.53 ▼32.71
Dashboard /wp-admin2.05 ▼1.305.72 ▼63.54
Posts /wp-admin/edit.php2.05 ▼1.316.27 ▼42.17
Add New Post /wp-admin/post-new.php2.05 ▼3.846.19 ▼101.89
Media Library /wp-admin/upload.php2.05 ▼1.185.21 ▼33.79

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 10 new files
Database: no new tables, 7 new options
New WordPress options
widget_tourdates
widget_recent-posts
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Tour Dates
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,809 ▲4814.35 ▼0.211.75 ▲0.0741.49 ▼4.30
Dashboard /wp-admin2,210 ▲305.48 ▼0.1884.35 ▼1.9041.17 ▲5.29
Posts /wp-admin/edit.php2,109 ▲91.96 ▼0.0040.81 ▲1.5534.54 ▲0.27
Add New Post /wp-admin/post-new.php1,536 ▲1023.54 ▲0.40695.51 ▲20.9057.14 ▲3.83
Media Library /wp-admin/upload.php1,409 ▲124.21 ▲0.03108.33 ▼5.8447.75 ▲1.49

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-content/plugins/seatgeek-tour-dates/tour-dates.php+370
    Function create_function() is deprecated
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_tourdates
    • theysaidso_admin_options
    • 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
Even though no errors were found, this is by no means an exhaustive test

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
The following issues need your attention
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/seatgeek-tour-dates/tour-dates-admin.php:18
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/seatgeek-tour-dates/tour-dates.php:13

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 issues were found

Optimizations

Plugin configuration 93% 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
Attributes that require attention:
  • Donate link: Invalid URI ("seatgeek.com")
You can take inspiration from this readme.txt

seatgeek-tour-dates/tour-dates.php 92% from 13 tests

Analyzing the main PHP file in "Tour Dates" version 1.1
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("seatgeek-tour-dates.php" instead of "tour-dates.php")

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
Good job! No executable or dangerous file extensions detected525 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP210023304
CSS2643221

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.16
Average class complexity9.00
▷ Minimum class complexity9.00
▷ Maximum class complexity9.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions7
▷ Named functions7100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.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
3 PNG files occupy 0.05MB with 0.02MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/seat-geek-logo.png1.75KB1.68KB▼ 4.01%
images/seat-geek-logo1.png1.73KB1.32KB▼ 23.62%
tour-dates-shortcode.png49.46KB15.40KB▼ 68.86%