78% next-event-calendar

Code Review | Next Event Calendar

WordPress plugin Next Event Calendar scored78%from 54 tests.

About plugin

  • Plugin page: next-event-calendar
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Nov 29, 2014
  • Latest release: Aug 7, 2015
  • Number of updates: 23
  • Update frequency: every 11.4 days
  • Top authors: afmarchetti (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

90+ active /7,737 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲0.16MB] [CPU: ▲1.26ms] Passed 4 tests

Analyzing server-side resources used by Next Event Calendar
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.63 ▲0.1748.91 ▲2.86
Dashboard /wp-admin3.46 ▲0.1551.22 ▲2.25
Posts /wp-admin/edit.php3.57 ▲0.2154.72 ▲4.86
Add New Post /wp-admin/post-new.php6.04 ▲0.1696.70 ▼4.94
Media Library /wp-admin/upload.php3.38 ▲0.1541.04 ▲5.85
All Events /wp-admin/edit.php?post_type=nec_events3.4242.02
Event Categories /wp-admin/edit-tags.php?taxonomy=nec_cat_events&post_type=nec_events3.3743.78
Add New /wp-admin/post-new.php?post_type=nec_events3.5455.61

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 19 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
db_upgraded
widget_recent-posts
widget_theysaidso_widget
widget_cl_widget
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Next Event Calendar
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,929 ▲16813.50 ▼0.879.89 ▲7.7443.79 ▼0.53
Dashboard /wp-admin2,233 ▲535.82 ▲0.1389.17 ▼2.1683.72 ▲39.64
Posts /wp-admin/edit.php2,159 ▲622.26 ▲0.2541.45 ▲2.2536.06 ▲0.44
Add New Post /wp-admin/post-new.php1,580 ▲4623.24 ▼0.09776.83 ▲105.5155.23 ▲2.48
Media Library /wp-admin/upload.php1,447 ▲474.37 ▲0.11100.59 ▼1.1281.79 ▲36.39
All Events /wp-admin/edit.php?post_type=nec_events1,1262.0536.6331.95
Event Categories /wp-admin/edit-tags.php?taxonomy=nec_cat_events&post_type=nec_events1,3272.2527.3232.78
Add New /wp-admin/post-new.php?post_type=nec_events2,9598.22181.23126.48

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_cl_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/next-event-calendar/loop-events.php
  • 4× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/next-event-calendar/widget.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/next-event-calendar/admin.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/next-event-calendar/next-event-calendar.php:42
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/next-event-calendar/single.php:83

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention: You can take inspiration from this readme.txt

next-event-calendar/next-event-calendar.php 92% from 13 tests

Analyzing the main PHP file in "Next Event Calendar" version 1.2
You should first fix the following items:
  • Description: The description should be shorter than 140 characters (currently 353 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected2,340 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript1155391,177
PHP5315149581
CSS2394331
PO File2106107251

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity17.00
▷ Minimum class complexity17.00
▷ Maximum class complexity17.00
Average method complexity5.00
▷ Minimum method complexity1.00
▷ Maximum method complexity12.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%
Functions17
▷ Named functions17100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
6 PNG files occupy 0.43MB with 0.34MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png287.80KB93.73KB▼ 67.43%
img/calendar.png1.06KB0.15KB▼ 86.19%
img/clock.png17.13KB1.79KB▼ 89.53%
screenshot-1.png127.48KB45.90KB▼ 64.00%
img/calendar_2.png5.68KB0.56KB▼ 90.08%