78% eventbrite-services

Code Review | Eventbrite Services

WordPress plugin Eventbrite Services scored 78% from 54 tests.

About plugin

  • Plugin page: eventbrite-services
  • Plugin version: 1.3.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.7-4.2.2
  • WordPress version: 5.8.1
  • First release: Oct 23, 2014
  • Latest release: May 13, 2015
  • Number of updates: 16
  • Update frequency: every 17.4 days
  • Top authors: smccafferty (81.25%)csloisel (25%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active / 7,207 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.49MB] [CPU: ▼180.56ms] Passed 4 tests

An overview of server-side resources used by Eventbrite Services
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.11 ▲0.3925.06 ▼0.04
Dashboard /wp-admin3.16 ▲0.1126.83 ▼33.20
Posts /wp-admin/edit.php3.16 ▲0.0623.87 ▼26.82
Add New Post /wp-admin/post-new.php3.16 ▼2.2719.86 ▼647.66
Media Library /wp-admin/upload.php3.16 ▲0.1623.85 ▼14.55
Eventbrite /wp-admin/tools.php?page=eventbrite-page3.1620.00
Keyring /wp-admin/tools.php?page=keyring3.1626.44

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 47 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for Eventbrite Services
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,698 ▲10215.82 ▲0.2514.63 ▲4.7149.33 ▲0.47
Dashboard /wp-admin2,985 ▲486.09 ▲0.11162.22 ▼18.92118.67 ▼3.39
Posts /wp-admin/edit.php2,758 ▲192.71 ▼0.0077.96 ▲5.1098.61 ▲2.64
Add New Post /wp-admin/post-new.php1,627 ▼5621.00 ▲4.91324.41 ▼116.10117.02 ▲0.76
Media Library /wp-admin/upload.php1,826 ▲195.08 ▲0.03181.92 ▲10.73123.80 ▲3.88
Eventbrite /wp-admin/tools.php?page=eventbrite-page1,0632.3462.7695.01
Keyring /wp-admin/tools.php?page=keyring1,1142.1074.8177.02

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
Please fix the following items
  • This plugin did not uninstall without warnings or errors
    • > Deprecated in wp-content/plugins/eventbrite-services/keyring/includes/oauth-php/OAuth.php+101
    Array and string offset access syntax with curly braces is deprecated

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/tools.php?page=keyring
    • > Deprecated in wp-content/plugins/eventbrite-services/keyring/includes/oauth-php/OAuth.php+101
    Array and string offset access syntax with curly braces is deprecated
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/tools.php?page=keyring
    • > User notice in wp-includes/functions.php+5663
    add_submenu_page was called incorrectly. The seventh parameter passed to add_submenu_page() should be an integer representing menu position. Please see Debugging in WordPress for more information. (This message was added in version 5.3.0.)
    • > GET request to /wp-admin/tools.php?page=keyring
    • > User deprecated in wp-includes/functions.php+5221
    screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/tools.php?page=keyring
    • > User deprecated in wp-includes/functions.php+5221
    get_screen_icon is deprecated since version 3.8.0 with no alternative available.

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 30× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/eventbrite-services/eventbrite-settings/eventbrite-settings.php on line 10
    • > PHP Fatal error
      Uncaught Error: Class 'Keyring_Store' not found in wp-content/plugins/eventbrite-services/keyring/includes/stores/singlestore.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/eventbrite-services/keyring/includes/oauth-php/tests/OAuthUtilTest.php:8
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/eventbrite-services/keyring/admin-ui.php on line 191
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Error' not found in wp-content/plugins/eventbrite-services/keyring/keyring.php:305
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/eventbrite-services/keyring/includes/oauth-php/tests/OAuthSignatureMethodPlaintextTest.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'Keyring_Service_OAuth2' not found in wp-content/plugins/eventbrite-services/eventbrite-keyring/eventbrite.php:10
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/eventbrite-services/eventbrite-settings/eventbrite-settings.php on line 10
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/eventbrite-services/keyring/includes/oauth-php/tests/OAuthConsumerTest.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/eventbrite-services/eventbrite-widgets/eventbrite-widgets.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)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Please fix the following attributes:
  • Screenshots: Please add images for these screenshots: #1 (Plugin name and description), #2 (Eventbrite Keyring connection), #3 (Eventbrite settings page)
The official readme.txt might help

eventbrite-services/eventbrite-services.php Passed 13 tests

"Eventbrite Services" version 1.3.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
72 characters long description:
Provides Eventbrite service, widgets, and features to supporting themes.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin5,222 lines of code in 39 files:
LanguageFilesBlank linesComment linesLines of code
PHP351,0881,5724,686
PO File1119134403
JavaScript13561
CSS16059
XML10013

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity11.14
▷ Minimum class complexity1.00
▷ Maximum class complexity56.00
Average method complexity2.51
▷ Minimum method complexity1.00
▷ Maximum method complexity22.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes58
▷ Abstract classes610.34%
▷ Concrete classes5289.66%
▷ Final classes00.00%
Methods398
▷ Static methods8421.11%
▷ Public methods37393.72%
▷ Protected methods51.26%
▷ Private methods205.03%
Functions13
▷ Named functions1076.92%
▷ Anonymous functions323.08%
Constants13
▷ Global constants753.85%
▷ Class constants646.15%
▷ Public constants6100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
3 PNG files occupy 0.20MB with 0.13MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png91.41KB32.45KB▼ 64.50%
screenshot-2.png41.44KB14.16KB▼ 65.84%
screenshot-3.png68.93KB22.90KB▼ 66.78%