10% gc-testimonials-with-recaptcha

Code Review | GC Testimonials with reCAPTCHA

WordPress plugin GC Testimonials with reCAPTCHA scored10%from 54 tests.

About plugin

  • Plugin page: gc-testimonials-w...
  • Plugin version: 1.3.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.9
  • WordPress version: 6.3.1
  • First release: May 14, 2014
  • Latest release: May 14, 2014
  • Number of updates: 2
  • Update frequency: every 7.5 days
  • Top authors: trishahdee (100%)

Code review

54 tests

User reviews

1 review

Install metrics

50+ active /1,888 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
These installer errors require your attention
  • The plugin cannot be installed
    • > Warning in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php+1034
    Use of undefined constant KCVT_URL - assumed 'KCVT_URL' (this will throw an Error in a future version of PHP)

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

Analyzing server-side resources used by GC Testimonials with reCAPTCHA
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.29 ▼1.189.95 ▼33.55
Dashboard /wp-admin2.05 ▼1.266.51 ▼46.13
Posts /wp-admin/edit.php2.05 ▼1.315.73 ▼43.50
Add New Post /wp-admin/post-new.php2.05 ▼3.845.75 ▼101.20
Media Library /wp-admin/upload.php2.05 ▼1.185.04 ▼28.18
Categories /wp-admin/edit-tags.php?taxonomy=testimonial-category&post_type=testimonial2.056.04
Add New /wp-admin/post-new.php?post_type=testimonial2.056.07
All Testimonials /wp-admin/edit.php?post_type=testimonial2.055.93
Settings /wp-admin/edit.php?post_type=testimonial&page=settings2.055.80

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 14 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
widget_gc-testimonial-widget
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for GC Testimonials with reCAPTCHA
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,864 ▲7814.40 ▲0.132.10 ▼0.2142.71 ▲0.03
Dashboard /wp-admin2,228 ▲485.66 ▲0.0690.88 ▼5.6677.85 ▲33.93
Posts /wp-admin/edit.php2,161 ▲612.03 ▲0.0937.75 ▲0.7833.84 ▲0.37
Add New Post /wp-admin/post-new.php1,571 ▲3623.06 ▲4.99764.78 ▲98.3660.48 ▼4.16
Media Library /wp-admin/upload.php1,445 ▲484.26 ▲0.05109.97 ▲2.8977.96 ▲32.47
Categories /wp-admin/edit-tags.php?taxonomy=testimonial-category&post_type=testimonial1,3072.2228.1230.80
Add New /wp-admin/post-new.php?post_type=testimonial2,4377.81177.61132.27
All Testimonials /wp-admin/edit.php?post_type=testimonial1,1442.0133.8228.52
Settings /wp-admin/edit.php?post_type=testimonial&page=settings1,0802.0134.6036.88

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • Uninstall procedure had uncaught errors
    • > Warning in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php+1034
    Use of undefined constant KCVT_URL - assumed 'KCVT_URL' (this will throw an Error in a future version of PHP)
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_gc-testimonial-widget
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These server-side errors were triggered
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=testimonial&page=settings
    • > Warning in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php+1034
    Use of undefined constant KCVT_URL - assumed 'KCVT_URL' (this will throw an Error in a future version of PHP)
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=testimonial&page=settings
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in GCT_Testimonial_Menu_Widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/post-new.php?post_type=testimonial
    • > Notice in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php+274
    Undefined index: client_name
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=testimonial
    • > Notice in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php+278
    Trying to access array offset on value of type null
    • > GET request to /wp-admin/post-new.php?post_type=testimonial
    • > Notice in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php+275
    Undefined index: client_photo
    • > GET request to /wp-admin/post-new.php?post_type=testimonial
    • > Notice in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php+276
    Undefined index: email
    • > GET request to /wp-admin/post-new.php?post_type=testimonial
    • > Notice in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php+277
    Undefined index: company_website
    • > GET request to /wp-admin/post-new.php?post_type=testimonial
    • > Notice in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php+278
    Undefined index: company_name
    • > GET request to /wp-admin/edit.php?post_type=testimonial&page=settings
    • > Notice in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php+1128
    Undefined index: testimonial_layout

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
Please take a closer look at the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/gc-testimonials-with-recaptcha/testimonials.php:30

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please fix the following user-side errors
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=testimonial&page=settings
    • > Network (severe)
    wp-content/plugins/gc-testimonials-recaptcha/assets/images/icon_16.png - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
5 plugin tags: user testimonials, manage testimonials, testimonial form, testimonial manager, testimonials

gc-testimonials-with-recaptcha/testimonials.php 92% from 13 tests

Analyzing the main PHP file in "GC Testimonials with reCAPTCHA" version 1.3.2
Please take the time to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("gc-testimonials-with-recaptcha.php" instead of "testimonials.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin2,895 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript41531631,411
PHP22961691,035
CSS3624294
PO File17076155

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity14.50
▷ Minimum class complexity1.00
▷ Maximum class complexity28.00
Average method complexity7.75
▷ Minimum method complexity1.00
▷ Maximum method complexity20.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions44
▷ Named functions44100.00%
▷ Anonymous functions00.00%
Constants7
▷ Global constants7100.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
2 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/quotes.png0.63KB0.37KB▼ 40.63%
assets/images/icon_16.png0.63KB0.58KB▼ 8.26%