79% azurecurve-flags

Code Review | azurecurve Flags

WordPress plugin azurecurve Flags scored79%from 54 tests.

About plugin

  • Plugin page: azurecurve-flags
  • Plugin version: 2.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-5.0.0
  • WordPress version: 6.3.1
  • First release: Mar 7, 2015
  • Latest release: Feb 23, 2020
  • Number of updates: 21
  • Update frequency: every 86.4 days
  • Top authors: azurecurve (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

500+ active /8,249 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼7.87ms] Passed 4 tests

Server-side resources used by azurecurve Flags
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0140.70 ▼11.13
Dashboard /wp-admin3.31 ▲0.0147.44 ▼5.95
Posts /wp-admin/edit.php3.37 ▲0.0157.53 ▲2.42
Add New Post /wp-admin/post-new.php5.90 ▲0.0191.78 ▼10.87
Media Library /wp-admin/upload.php3.24 ▲0.0138.95 ▼3.51
Flags /wp-admin/admin.php?page=azc-f3.1937.64
Plugins /wp-admin/admin.php?page=azc-plugin-menus3.2041.15

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

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

Browser metrics Passed 4 tests

azurecurve Flags: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,844 ▲8314.27 ▼0.051.76 ▼0.3146.35 ▼0.92
Dashboard /wp-admin2,208 ▲315.56 ▼0.1294.01 ▼6.2180.38 ▲30.24
Posts /wp-admin/edit.php2,135 ▲351.98 ▼0.0139.21 ▼2.2235.93 ▼6.02
Add New Post /wp-admin/post-new.php1,550 ▲2423.34 ▲2.33692.28 ▼26.1949.31 ▼10.56
Media Library /wp-admin/upload.php1,428 ▲254.11 ▼0.08116.73 ▲4.1077.79 ▲27.40
Flags /wp-admin/admin.php?page=azc-f2,1162.1238.2480.23
Plugins /wp-admin/admin.php?page=azc-plugin-menus8702.0029.4830.60

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/admin.php?page=azc-f
    • > Notice in wp-content/plugins/azurecurve-flags/azurecurve-flags.php+425
    Undefined index: AN
    • > GET request to /wp-admin/admin.php?page=azc-f
    • > Notice in wp-content/plugins/azurecurve-flags/azurecurve-flags.php+425
    Undefined index: CATALONIA
    • > GET request to /wp-admin/admin.php?page=azc-f
    • > Notice in wp-content/plugins/azurecurve-flags/azurecurve-flags.php+425
    Undefined index: FAM
    • > GET request to /wp-admin/admin.php?page=azc-f
    • > Notice in wp-content/plugins/azurecurve-flags/azurecurve-flags.php+425
    Undefined index: NONE

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/azurecurve-flags/includes/menu.php:29
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/azurecurve-flags/includes/menu.php:29

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
6 plugin tags: pages, classicpress, posts, flags, shortcode...

azurecurve-flags/azurecurve-flags.php Passed 13 tests

The main PHP script in "azurecurve Flags" version 2.2.0 is automatically included on every request by WordPress
72 characters long description:
Allows a 16x16 flag to be displayed in a post of page using a shortcode.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected581 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP33833562
CSS20419

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.65
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
254 compressed PNG files occupy 0.13MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/ba.png0.58KB0.71KB0.00%
images/lv.png0.45KB0.71KB0.00%
images/hk.png0.51KB0.65KB0.00%
images/am.png0.49KB0.71KB0.00%
images/mn.png0.48KB0.67KB0.00%