78% chirpyweb

Code Review | ChirpyWeb - Web Push Notifications

WordPress plugin ChirpyWeb - Web Push Notifications scored78%from 54 tests.

About plugin

  • Plugin page: chirpyweb
  • Plugin version: 1.3
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.2.2
  • WordPress version: 6.3.1
  • First release: Mar 28, 2022
  • Latest release: May 30, 2023
  • Number of updates: 21
  • Update frequency: every 20.5 days
  • Top authors: chirpyweb (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,208 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

An overview of server-side resources used by ChirpyWeb - Web Push Notifications
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1538.03 ▼0.32
Dashboard /wp-admin3.46 ▲0.1646.85 ▼1.60
Posts /wp-admin/edit.php3.58 ▲0.2248.18 ▲3.57
Add New Post /wp-admin/post-new.php6.07 ▲0.1885.49 ▼13.57
Media Library /wp-admin/upload.php3.39 ▲0.1638.31 ▲3.22

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for ChirpyWeb - Web Push Notifications
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,852 ▲10613.31 ▼1.0516.81 ▲14.7342.18 ▼1.92
Dashboard /wp-admin2,221 ▲365.82 ▲0.78103.75 ▼12.4778.70 ▲32.69
Posts /wp-admin/edit.php2,121 ▲321.98 ▼0.0636.14 ▼3.8733.16 ▼5.25
Add New Post /wp-admin/post-new.php1,683 ▲15922.10 ▼1.28734.65 ▲104.3951.13 ▼6.52
Media Library /wp-admin/upload.php1,406 ▲214.13 ▼0.10105.63 ▲3.6670.21 ▲23.35

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
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 0% 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
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/chirpyweb/templates/header_script.php
  • 3× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/chirpyweb/includes/admin.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/chirpyweb/includes/class-chirpyweb-init.php:25
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/chirpyweb/templates/admin.php:11

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% 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
Please fix the following attributes:
  • Screenshots: No descriptions were found for these screenshots #1, #2, #3, #4, #5, #6 in chirpyweb/assets to your readme.txt
  • Tags: Please delete some tags, you are using 33 tag instead of maximum 10
The official readme.txt is a good inspiration

chirpyweb/chirpyweb.php Passed 13 tests

The main PHP file in "ChirpyWeb - Web Push Notifications" ver. 1.3 adds more information about the plugin and also serves as the entry point for this plugin
125 characters long description:
ChirpyWeb supports push notifications on all browsers including Chrome, Firefox, Safari, Microsoft Edge, Opera and many more.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin1,198 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP658237838
CSS121189
JavaScript1133129
SVG10142

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity70.00
▷ Minimum class complexity70.00
▷ Maximum class complexity70.00
Average method complexity3.30
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods30
▷ Static methods620.00%
▷ Public methods30100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions9
▷ Named functions888.89%
▷ Anonymous functions111.11%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.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.42MB with 0.26MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/Chirpy Web Logo - Full.png126.13KB44.63KB▼ 64.62%
assets/images/menu-icon.png150.89KB56.45KB▼ 62.59%
assets/images/Chirpy Web Logo - Short.png150.89KB56.45KB▼ 62.59%