78% cf7-icons-and-labels

Code Review | Cf7 Icons and Labels

WordPress plugin Cf7 Icons and Labels scored 78% from 54 tests.

About plugin

  • Plugin page: cf7-icons-and-labels
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.2-4.9
  • WordPress version: 6.3.1
  • First release: May 25, 2017
  • Latest release: Dec 10, 2017
  • Number of updates: 24
  • Update frequency: every 8.4 days
  • Top authors: codeaid (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

800+ active / 5,507 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

This is a short check of server-side resources used by Cf7 Icons and Labels
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0135.86 ▼7.82
Dashboard /wp-admin3.32 ▲0.0242.57 ▼5.87
Posts /wp-admin/edit.php3.37 ▲0.0145.23 ▼3.66
Add New Post /wp-admin/post-new.php5.90 ▲0.0189.45 ▼12.20
Media Library /wp-admin/upload.php3.24 ▲0.0135.73 ▲2.27
Cf7 Icons and labels /wp-admin/options-general.php?page=CF7-icons-and-labels3.1828.22

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-comments
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

Cf7 Icons and Labels: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,866 ▲10913.29 ▼1.094.53 ▲1.9443.27 ▼3.51
Dashboard /wp-admin2,207 ▲554.87 ▼0.70114.09 ▲3.2443.78 ▼3.86
Posts /wp-admin/edit.php2,093 ▲41.97 ▼0.0839.34 ▼0.5734.63 ▲2.51
Add New Post /wp-admin/post-new.php1,545 ▲2618.36 ▼4.94648.31 ▼32.0655.41 ▼5.05
Media Library /wp-admin/upload.php1,383 ▼84.18 ▼0.0798.72 ▼3.2842.96 ▼1.18
Cf7 Icons and labels /wp-admin/options-general.php?page=CF7-icons-and-labels8062.0327.6029.94

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
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
These server-side errors were triggered
    • > GET request to /wp-admin/options-general.php?page=CF7-icons-and-labels
    • > User deprecated in wp-includes/functions.php+5463
    Function screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=CF7-icons-and-labels
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please take a closer look at the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/cf7-icons-and-labels/cf7-icons-and-labels.php:22

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need to be fixed:
  • Tags: Please reduce the number of tags, currently 27 tag instead of maximum 10
You can look at the official readme.txt

cf7-icons-and-labels/cf7-icons-and-labels.php Passed 13 tests

The main PHP file in "Cf7 Icons and Labels" ver. 1.3 adds more information about the plugin and also serves as the entry point for this plugin
105 characters long description:
This plugin modifies the output of the popular Contact Form 7 plugin to add font awesome icons and labels

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
There were no executable files found in this plugin254 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
CSS13291
PHP1412390
JavaScript1122073

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity13.00
▷ Minimum class complexity13.00
▷ Maximum class complexity13.00
Average method complexity2.33
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods9
▷ Static methods00.00%
▷ Public methods9100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
There are no PNG files in this plugin