10% push-envoy

Code Review | Push Envoy Notifications

WordPress plugin Push Envoy Notifications scored 10% from 54 tests.

About plugin

  • Plugin page: push-envoy
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.8
  • WordPress version: 6.3.1
  • First release: Aug 7, 2017
  • Latest release: Aug 7, 2017
  • Number of updates: 9
  • Update frequency: every 0.1 days
  • Top authors: netbitsolutions (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 628 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The following installer errors require your attention
  • This plugin did not install gracefully
    • > Notice in wp-content/plugins/push-envoy/pushenvoy.php+77
    Undefined index: app_id

Server metrics [RAM: ▼0.74MB] [CPU: ▼30.12ms] 75% from 4 tests

An overview of server-side resources used by Push Envoy Notifications
The following require your attention
  • CPU: Total CPU usage should be kept under 500.00ms (currently 1,544.47ms on /wp-admin/admin.php?page=push_en_io_dash)
PageMemory (MB)CPU Time (ms)
Home /3.68 ▲0.2241.79 ▲2.39
Dashboard /wp-admin3.21 ▼0.1024.46 ▼23.40
Posts /wp-admin/edit.php3.21 ▼0.1523.56 ▼22.02
Add New Post /wp-admin/post-new.php3.21 ▼2.6825.19 ▼63.18
Media Library /wp-admin/upload.php3.21 ▼0.0222.22 ▼11.88
Instant Message /wp-admin/admin.php?page=push_en_io_send_msg3.4736.58
PushEnvoy /wp-admin/admin.php?page=push_en_io_dash3.461,544.47
Segmentation /wp-admin/admin.php?page=push_en_io_segment3.46262.91
Settings /wp-admin/admin.php?page=push_en_io_settings3.4431.26

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 57 new files
Database: 2 new tables, 7 new options
New tables
wp_push_en_user_msg
wp_push_auto_post
New WordPress options
push_en_settings
db_upgraded
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Push Envoy Notifications
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,888 ▲13113.73 ▼0.654.62 ▲2.7146.72 ▲6.88
Dashboard /wp-admin2,279 ▲915.05 ▼0.85115.90 ▲10.1280.16 ▲40.32
Posts /wp-admin/edit.php2,142 ▲502.30 ▲0.2533.61 ▼1.5532.69 ▲0.35
Add New Post /wp-admin/post-new.php6,518 ▲4,98520.48 ▼2.62926.00 ▲248.5236.76 ▼16.39
Media Library /wp-admin/upload.php1,439 ▲514.49 ▲0.3296.86 ▼9.6876.82 ▲31.97
Instant Message /wp-admin/admin.php?page=push_en_io_send_msg1,0793.3347.49105.25
PushEnvoy /wp-admin/admin.php?page=push_en_io_dash1,0093.3440.2268.96
Segmentation /wp-admin/admin.php?page=push_en_io_segment1,0923.3440.2768.76
Settings /wp-admin/admin.php?page=push_en_io_settings1,2693.3442.9271.20

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% 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 without warnings or errors
    • > Notice in wp-content/plugins/push-envoy/includes/script_styles.php+7
    Undefined index: page
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/admin.php?page=push_en_io_dash
    • > Notice in wp-content/plugins/push-envoy/process/adminclass.php+333
    Trying to get property 'respond' of non-object
    • > GET request to /wp-admin/admin.php?page=push_en_io_dash
    • > Notice in wp-content/plugins/push-envoy/process/adminclass.php+339
    Trying to get property 'message' of non-object
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=push_en_io_dash
    • > Notice in wp-content/plugins/push-envoy/admin/dashboard.php+71
    Undefined index: log
    • > GET request to /wp-admin/admin.php?page=push_en_io_segment
    • > Notice in wp-content/plugins/push-envoy/admin/segmentation.php+22
    Undefined index: data
    • > GET request to /wp-admin/admin.php?page=push_en_io_segment
    • > Warning in wp-content/plugins/push-envoy/admin/segmentation.php+22
    count(): Parameter must be an array or an object that implements Countable
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=push_en_io_settings
    • > Notice in wp-content/plugins/push-envoy/admin/setting.php+20
    Undefined index: status
    • > GET request to /wp-admin/admin.php?page=push_en_io_settings
    • > Notice in wp-content/plugins/push-envoy/admin/setting.php+33
    Undefined index: appid

SRP Passed 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% 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
3 plugin tags: wordpress push notifications, push notifications, push notification plugin

push-envoy/pushenvoy.php 77% from 13 tests

The principal PHP file in "Push Envoy Notifications" v. 1.0.0 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("push-envoy.php" instead of "pushenvoy.php")
  • Text Domain: The text domain name must use dashes instead of underscores, and it must be lowercase
  • Domain Path: The domain path is invalid: folder "/languages" does not exist

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
Success! There were no dangerous files found in this plugin12,360 lines of code in 39 files:
LanguageFilesBlank linesComment linesLines of code
CSS619257,622
JavaScript79563502,952
PHP254661421,498
SVG100288

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity15.00
▷ Minimum class complexity1.00
▷ Maximum class complexity29.00
Average method complexity2.47
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods19
▷ Static methods00.00%
▷ Public methods19100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions24
▷ Named functions24100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
4 PNG files occupy 0.10MB with 0.05MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
passets/img/pushenvoy.png69.40KB5.51KB▼ 92.06%
passets/img/pushicon.png12.24KB5.13KB▼ 58.04%
passets/img/noicon.png1.14KB1.03KB▼ 9.93%
passets/img/delete.png17.55KB12.29KB▼ 29.96%