83% floating-contact-buttons

Code Review | Instant Support Buttons - Call, Contact, Chat, Email

WordPress plugin Instant Support Buttons - Call, Contact, Chat, Email scored 83% from 54 tests.

About plugin

  • Plugin page: floating-contact-...
  • Plugin version: 1.1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.3
  • WordPress version: 6.3.1
  • First release: Mar 1, 2019
  • Latest release: Aug 5, 2023
  • Number of updates: 26
  • Update frequency: every 62.5 days
  • Top authors: Narinder singh (100%)

Code review

54 tests

User reviews

53 reviews

Install metrics

2,000+ active / 19,934 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.27MB] [CPU: ▼1.90ms] Passed 4 tests

Server-side resources used by Instant Support Buttons - Call, Contact, Chat, Email
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.65 ▲0.1941.63 ▲0.92
Dashboard /wp-admin3.65 ▲0.3551.32 ▲1.83
Posts /wp-admin/edit.php3.70 ▲0.3557.58 ▲7.23
Add New Post /wp-admin/post-new.php6.17 ▲0.2887.08 ▼9.77
Media Library /wp-admin/upload.php3.49 ▲0.2640.78 ▼0.58
Instant Support Buttons /wp-admin/options-general.php?page=instant_support_buttons3.4936.39

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 51 new files
Database: no new tables, 12 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
fcb-type
fcb-alreadyRated
fcb-v
can_compress_scripts
fcb_style_settings
widget_theysaidso_widget
db_upgraded
widget_recent-comments
...

Browser metrics Passed 4 tests

An overview of browser requirements for Instant Support Buttons - Call, Contact, Chat, Email
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,203 ▲46815.54 ▲1.329.72 ▲7.6346.53 ▼4.07
Dashboard /wp-admin2,371 ▲1836.66 ▲1.76135.33 ▲22.7841.94 ▲1.38
Posts /wp-admin/edit.php2,271 ▲1823.52 ▲1.4953.55 ▲12.4234.24 ▼2.74
Add New Post /wp-admin/post-new.php1,533 ▼023.18 ▼0.02611.07 ▼76.6136.45 ▼37.22
Media Library /wp-admin/upload.php1,413 ▲224.32 ▲0.1982.86 ▼26.7841.97 ▼5.57
Instant Support Buttons /wp-admin/options-general.php?page=instant_support_buttons1,5743.7572.5228.05

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • The uninstall procedure has failed, leaving 12 options in the database
    • db_upgraded
    • fcb-alreadyRated
    • can_compress_scripts
    • widget_recent-posts
    • fcb-v
    • fcb-installDate
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget
    • fcb_style_settings
    • ...

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

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
Almost there! Just fix the following items
  • 3× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Warning
      Use of undefined constant FCB_VERSION - assumed 'FCB_VERSION' (this will throw an Error in a future version of PHP) in wp-content/plugins/floating-contact-buttons/feedback/admin-feedback-form.php on line 171
    • > PHP Warning
      Use of undefined constant FCB_URL - assumed 'FCB_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/floating-contact-buttons/feedback/admin-feedback-form.php on line 171
    • > PHP Fatal error
      Uncaught Error: Call to undefined function FCB\\feedback\\add_action() in wp-content/plugins/floating-contact-buttons/feedback/admin-feedback-form.php:18

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 86% 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: The official readme.txt might help

floating-contact-buttons/floating-contact-buttons.php 77% from 13 tests

This is the main PHP file of "Instant Support Buttons - Call, Contact, Chat, Email" version 1.1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please take the time to fix the following:
  • Domain Path: Use only dashes and lowercase characters for the domain path ("languages")
  • Domain Path: The domain path should be prefixed with a forward slash character ("/languages")
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin2,507 lines of code in 27 files:
LanguageFilesBlank linesComment linesLines of code
PHP72282701,124
JavaScript610360615
CSS64457393
PO File7105105344
SVG119031

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity22.17
▷ Minimum class complexity4.00
▷ Maximum class complexity69.00
Average method complexity2.86
▷ Minimum method complexity1.00
▷ Maximum method complexity34.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes116.67%
Methods58
▷ Static methods35.17%
▷ Public methods5798.28%
▷ Protected methods00.00%
▷ Private methods11.72%
Functions4
▷ Named functions375.00%
▷ Anonymous functions125.00%
Constants4
▷ Global constants4100.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
10 compressed PNG files occupy 0.01MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/fcb_phone.png0.73KB0.86KB0.00%
assets/images/fcb_email.png0.82KB0.92KB0.00%
assets/images/fcb-logo.png4.46KB4.67KB0.00%
assets/images/fcb_facebook.png0.45KB0.45KB0.00%
assets/images/fcb_close.png0.43KB0.41KB▼ 3.66%