90% fcm-push-notification-from-wp

Code Review | FCM Push Notification from WP

WordPress plugin FCM Push Notification from WP scored90%from 54 tests.

About plugin

  • Plugin page: fcm-push-notifica...
  • Plugin version: 1.9.0
  • PHP compatiblity: 5.6.20+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.8.2
  • WordPress version: 6.3.1
  • First release: Feb 1, 2020
  • Latest release: Dec 31, 2021
  • Number of updates: 25
  • Update frequency: every 28.0 days
  • Top authors: dprogrammer (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

1,000+ active /9,311 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.06MB] [CPU: ▼7.54ms] Passed 4 tests

A check of server-side resources used by FCM Push Notification from WP
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0739.22 ▲0.04
Dashboard /wp-admin3.38 ▲0.0344.40 ▼17.19
Posts /wp-admin/edit.php3.49 ▲0.1347.48 ▼5.05
Add New Post /wp-admin/post-new.php5.96 ▲0.0786.47 ▼7.95
Media Library /wp-admin/upload.php3.30 ▲0.0736.77 ▲1.47
Test Notification /wp-admin/admin.php?page=test_push_notification3.28281.47
FCM Push Notification from WP /wp-admin/options-general.php?page=fcmdpplgpn_push_notification3.3135.71

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for FCM Push Notification from WP
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.29 ▼1.081.70 ▼0.1546.05 ▼0.31
Dashboard /wp-admin2,213 ▲224.84 ▼0.0198.26 ▼11.1039.56 ▼6.06
Posts /wp-admin/edit.php2,093 ▲41.99 ▼0.0635.10 ▼6.1531.63 ▼5.20
Add New Post /wp-admin/post-new.php1,536 ▲723.22 ▲5.07686.59 ▲43.6253.40 ▼0.36
Media Library /wp-admin/upload.php1,386 ▲14.23 ▲0.0495.58 ▼2.7242.32 ▼5.37
Test Notification /wp-admin/admin.php?page=test_push_notification6671.536.6422.40
FCM Push Notification from WP /wp-admin/options-general.php?page=fcmdpplgpn_push_notification9162.1623.6625.35

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

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

SRP Passed 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
7 plugin tags: firebase, flutter, notification, ios, fcm...

fcm-push-notification-from-wp/fcm-dp-push-notification.php 92% from 13 tests

Analyzing the main PHP file in "FCM Push Notification from WP" version 1.9.0
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("fcm-push-notification-from-wp.php" instead of "fcm-dp-push-notification.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected366 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2142108366

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity19.00
▷ Minimum class complexity1.00
▷ Maximum class complexity37.00
Average method complexity3.12
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods17
▷ Static methods00.00%
▷ Public methods1694.12%
▷ Protected methods00.00%
▷ Private methods15.88%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
PNG images were not found in this plugin