78% link-google-calendar

Code Review | Link Google Calendar

WordPress plugin Link Google Calendar scored78%from 54 tests.

About plugin

  • Plugin page: link-google-calendar
  • Plugin version: 2.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.9.5
  • WordPress version: 6.3.1
  • First release: Oct 1, 2015
  • Latest release: May 2, 2018
  • Number of updates: 8
  • Update frequency: every 118.1 days
  • Top authors: dxladner (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

500+ active /7,248 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
Installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼3.85ms] Passed 4 tests

Server-side resources used by Link Google Calendar
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0438.09 ▼8.10
Dashboard /wp-admin3.35 ▲0.0550.75 ▼3.11
Posts /wp-admin/edit.php3.41 ▲0.0452.27 ▼1.74
Add New Post /wp-admin/post-new.php5.93 ▲0.0495.26 ▲0.26
Media Library /wp-admin/upload.php3.28 ▲0.0434.44 ▼2.43
Number of Calendars /wp-admin/admin.php?page=link-google-number-of-calendar-options3.2432.36
Link Google Calendar Options /wp-admin/admin.php?page=link-google-calendar-options3.2430.58

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 12 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

Link Google Calendar: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,812 ▲5114.27 ▼0.322.00 ▲0.1843.11 ▼0.71
Dashboard /wp-admin2,215 ▲355.63 ▼0.0490.36 ▼7.2837.38 ▼6.93
Posts /wp-admin/edit.php2,120 ▲202.03 ▲0.0339.21 ▲2.9535.70 ▼6.09
Add New Post /wp-admin/post-new.php1,554 ▲2818.30 ▼5.22642.88 ▼47.6863.39 ▲10.29
Media Library /wp-admin/upload.php1,420 ▲234.18 ▼0.0098.53 ▼26.7847.19 ▼3.76
Number of Calendars /wp-admin/admin.php?page=link-google-number-of-calendar-options9132.0025.6927.12
Link Google Calendar Options /wp-admin/admin.php?page=link-google-calendar-options8892.0028.0129.63

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options

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
Everything seems fine, however this is by no means an exhaustive test

SRP 0% 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
The following issues need your attention
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/link-google-calendar/languages/index.php
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/link-google-calendar/link-google-calendar.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 96% 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
4 plugin tags: calendar, embedded google calendar, google calendar embed link, google calendar

link-google-calendar/link-google-calendar.php 92% from 13 tests

"Link Google Calendar" version 2.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • Requires at least: The required version number must match the one declared in readme.txt ("3.5" instead of "4.0")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected294 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP33214294

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.11
Average class complexity12.00
▷ Minimum class complexity12.00
▷ Maximum class complexity12.00
Average method complexity1.85
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods13
▷ Static methods00.00%
▷ Public methods13100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
8 PNG files occupy 0.26MB with 0.11MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-4.png38.75KB13.44KB▼ 65.31%
assets/screenshot-2.png47.69KB18.27KB▼ 61.68%
assets/icon-256x256.png9.02KB8.07KB▼ 10.54%
assets/screenshot-3.png81.89KB32.10KB▼ 60.81%
assets/banner-772x250.png15.71KB14.74KB▼ 6.17%