68% wp-click-to-call-calledin

Code Review | Called.in Click To Call Plugin

WordPress plugin Called.in Click To Call Plugin scored68%from 54 tests.

About plugin

  • Plugin page: wp-click-to-call-...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.0
  • WordPress version: 6.3.1
  • First release: Aug 21, 2014
  • Latest release: Sep 5, 2014
  • Number of updates: 10
  • Update frequency: every 1.6 days
  • Top authors: ronakdave (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /866 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▼1.70MB] [CPU: ▼50.40ms] Passed 4 tests

This is a short check of server-side resources used by Called.in Click To Call Plugin
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.29 ▼1.1710.24 ▼30.36
Dashboard /wp-admin2.31 ▼1.0011.50 ▼40.03
Posts /wp-admin/edit.php2.31 ▼1.0511.15 ▼39.10
Add New Post /wp-admin/post-new.php2.31 ▼3.5811.35 ▼92.11
Media Library /wp-admin/upload.php2.31 ▼0.929.78 ▼23.74
Called Settings /wp-admin/options-general.php?page=called2.3110.47

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 6 new files
Database: no new tables, 7 new options
New WordPress options
widget_called_widget
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

Called.in Click To Call Plugin: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,796 ▲1014.69 ▲0.342.41 ▲0.2940.69 ▼3.33
Dashboard /wp-admin2,199 ▲225.63 ▼0.0393.16 ▲0.8944.77 ▼1.69
Posts /wp-admin/edit.php2,104 ▼02.03 ▲0.0439.32 ▼0.5434.87 ▲0.59
Add New Post /wp-admin/post-new.php1,529 ▲321.39 ▼1.89643.05 ▲22.5550.64 ▲0.03
Media Library /wp-admin/upload.php1,404 ▲104.16 ▼0.0094.23 ▼4.5344.13 ▼1.88
Called Settings /wp-admin/options-general.php?page=called8351.9926.7428.76

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
Please fix the following items
  • This plugin did not uninstall without warnings or errors
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in Called_in_Widget is deprecated since version 4.3.0! Use __construct() instead.
  • The uninstall procedure has failed, leaving 7 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_called_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Please fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=called
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in Called_in_Widget is deprecated since version 4.3.0! Use __construct() instead.

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/wp-click-to-call-calledin/called.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function current_user_can() in wp-content/plugins/wp-click-to-call-calledin/back-end.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that need to be fixed:
  • Screenshots: Add images for these screenshots: #1 (screenshot-1.png), #2 (screenshot-2.png)
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === wp-click-to-call-calledin === )
The official readme.txt is a good inspiration

wp-click-to-call-calledin/called.php 92% from 13 tests

The primary PHP file in "Called.in Click To Call Plugin" version 1.0 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Main file name: Name the main plugin file the same as the plugin slug ("wp-click-to-call-calledin.php" instead of "called.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
No dangerous file extensions were detected210 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP3640210

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.07
Average class complexity4.00
▷ Minimum class complexity4.00
▷ Maximum class complexity4.00
Average method complexity1.75
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
2 PNG files occupy 0.07MB with 0.04MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png25.81KB13.95KB▼ 45.95%
screenshot-1.png47.33KB22.54KB▼ 52.37%