83% covid19-popup

Code Review | Coronavirus (COVID-19) Live Update Popup

WordPress plugin Coronavirus (COVID-19) Live Update Popup scored83%from 54 tests.

About plugin

  • Plugin page: covid19-popup
  • Plugin version: 2.3
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.1-5.4
  • WordPress version: 6.3.1
  • First release: Apr 21, 2020
  • Latest release: Jun 12, 2020
  • Number of updates: 14
  • Update frequency: every 3.7 days
  • Top authors: abuomama (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

10+ active /1,572 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲3.25MB] [CPU: ▲23.42ms] Passed 4 tests

Server-side resources used by Coronavirus (COVID-19) Live Update Popup
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /6.52 ▲3.0668.55 ▲25.95
Dashboard /wp-admin6.61 ▲3.3077.78 ▲26.10
Posts /wp-admin/edit.php6.66 ▲3.3084.18 ▲32.00
Add New Post /wp-admin/post-new.php9.23 ▲3.35108.73 ▲14.59
Media Library /wp-admin/upload.php6.55 ▲3.3262.99 ▲27.04

Server storage [IO: ▲7.23MB] [DB: ▲0.00MB] 67% from 3 tests

A short overview of filesystem and database impact
Please try to fix the following items
  • Illegal file modification found: 1 file (4.00KB) outside of "wp-content/plugins/covid19-popup/" and "wp-content/uploads/"
    • (new file) wp-content/mgd_mirror/mgd_maximinodotpy-gitdown-test-repository
Filesystem: 252 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
acf_version
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Coronavirus (COVID-19) Live Update Popup
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,926 ▲16513.63 ▼0.755.20 ▲3.4239.57 ▼2.86
Dashboard /wp-admin2,235 ▲325.85 ▼0.0497.46 ▼11.5342.55 ▼0.63
Posts /wp-admin/edit.php2,111 ▲111.99 ▼0.0637.33 ▼3.8733.58 ▼3.35
Add New Post /wp-admin/post-new.php6,669 ▲5,12427.90 ▲4.781,014.36 ▲300.3138.65 ▼21.02
Media Library /wp-admin/upload.php1,950 ▲5478.38 ▲4.15227.44 ▲118.1651.91 ▲5.11

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 does not fully uninstall, leaving 7 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • acf_version
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% 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
Please fix the following items
  • 78× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function acf_get_location_rule_types() in wp-content/plugins/covid19-popup/includes/acf/includes/admin/views/html-location-rule.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'acf_field' not found in wp-content/plugins/covid19-popup/includes/acf/includes/fields/class-acf-field-output.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'acf_field' not found in wp-content/plugins/covid19-popup/includes/acf/includes/fields/class-acf-field-link.php:5
    • > PHP Notice
      Undefined variable: active in wp-content/plugins/covid19-popup/includes/acf/includes/admin/views/html-admin-tools.php on line 16
    • > PHP Fatal error
      Uncaught Error: Class 'acf_field' not found in wp-content/plugins/covid19-popup/includes/acf/includes/fields/class-acf-field-true_false.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/covid19-popup/includes/acf/includes/upgrades.php:450
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/covid19-popup/includes/acf/includes/admin/views/html-admin-page-upgrade-network.php:24
    • > PHP Fatal error
      Uncaught Error: Class 'acf_field' not found in wp-content/plugins/covid19-popup/includes/acf/includes/fields/class-acf-field-taxonomy.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'acf_field' not found in wp-content/plugins/covid19-popup/includes/acf/includes/fields/class-acf-field-group.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function acf() in wp-content/plugins/covid19-popup/includes/acf/pro/acf-pro.php:23

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
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
Attributes that require attention: You can look at the official readme.txt

covid19-popup/covid19-popup.php 92% from 13 tests

The principal PHP file in "Coronavirus (COVID-19) Live Update Popup" v. 2.3 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

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 detected90,145 lines of code in 202 files:
LanguageFilesBlank linesComment linesLines of code
PO File3123,20838,00848,817
JavaScript187,1787,00723,485
PHP13710,92717,85216,059
CSS14208601,630
JSON100124
SVG118030

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity12.02
▷ Minimum class complexity1.00
▷ Maximum class complexity56.00
Average method complexity2.70
▷ Minimum method complexity1.00
▷ Maximum method complexity24.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes102
▷ Abstract classes00.00%
▷ Concrete classes102100.00%
▷ Final classes00.00%
Methods660
▷ Static methods00.00%
▷ Public methods660100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions436
▷ Named functions436100.00%
▷ Anonymous functions00.00%
Constants11
▷ Global constants11100.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
7 compressed PNG files occupy 0.02MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/acf/assets/inc/datepicker/images/ui-icons_ffffff_256x240.png3.68KB4.17KB0.00%
includes/acf/assets/images/acf-logo.png3.40KB3.39KB0.23%
includes/acf/assets/inc/select2/3/select2x2.png0.64KB0.77KB0.00%
includes/acf/assets/inc/datepicker/images/ui-bg_highlight-soft_0_ffffff_1x100.png0.08KB0.08KB0.00%
includes/acf/assets/inc/datepicker/images/ui-icons_DDDDDD_256x240.png3.68KB4.17KB0.00%