10% review-wave-google-places-reviews

Code Review | Review Wave - Google Places Reviews

WordPress plugin Review Wave - Google Places Reviews scored10%from 54 tests.

About plugin

  • Plugin page: review-wave-googl...
  • Plugin version: 1.4.7
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0.0-4.5.3
  • WordPress version: 6.3.1
  • First release: Aug 5, 2016
  • Latest release: Dec 6, 2017
  • Number of updates: 31
  • Update frequency: every 15.7 days
  • Top authors: MessageMetric (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

100+ active /4,690 total downloads

Benchmarks

Plugin footprint 23% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The following installer errors require your attention
  • The plugin cannot be installed
    • > Deprecated in wp-content/plugins/review-wave-google-places-reviews/rw_gplaces.php+62
    Function create_function() is deprecated

Server metrics [RAM: ▼1.66MB] [CPU: ▼53.95ms] Passed 4 tests

This is a short check of server-side resources used by Review Wave - Google Places Reviews
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.27 ▼1.197.04 ▼37.10
Dashboard /wp-admin2.37 ▼0.949.67 ▼40.32
Posts /wp-admin/edit.php2.37 ▼0.996.60 ▼50.83
Add New Post /wp-admin/post-new.php2.37 ▼3.527.35 ▼87.55
Media Library /wp-admin/upload.php2.37 ▼0.866.47 ▼31.78

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 15 new files
Database: 2 new tables, 8 new options
New tables
wp_rw_gplaces_review
wp_rw_gplaces_place
New WordPress options
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget
widget_recent-comments
rw_gplaces_options
widget_recent-posts
widget_review_wave_gplaces_reviews_widget
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Review Wave - Google Places Reviews
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,821 ▲7513.61 ▼0.691.79 ▼0.0843.72 ▼4.57
Dashboard /wp-admin2,211 ▲235.82 ▲0.95113.69 ▲1.3275.72 ▲35.45
Posts /wp-admin/edit.php2,106 ▲142.00 ▼0.0535.25 ▼9.9335.86 ▼5.29
Add New Post /wp-admin/post-new.php1,692 ▲15924.39 ▲1.37667.70 ▲14.2860.51 ▲0.73
Media Library /wp-admin/upload.php1,402 ▲114.18 ▼0.1898.59 ▼9.9173.21 ▲28.05

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-content/plugins/review-wave-google-places-reviews/rw_gplaces.php+62
    Function create_function() is deprecated
  • The uninstall procedure failed, leaving 2 tables in the database
    • wp_rw_gplaces_place
    • wp_rw_gplaces_review
  • This plugin does not fully uninstall, leaving 8 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_review_wave_gplaces_reviews_widget
    • widget_theysaidso_widget
    • rw_gplaces_options
    • db_upgraded

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)
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 5× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/review-wave-google-places-reviews/rw_gplaces.php
    • > /wp-content/plugins/review-wave-google-places-reviews/classes/widget.class.php
    • > /wp-content/plugins/review-wave-google-places-reviews/classes/review.model.php
    • > /wp-content/plugins/review-wave-google-places-reviews/classes/place.model.php
    • > /wp-content/plugins/review-wave-google-places-reviews/classes/abstract.model.php

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 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === review-wave-google-places-reviews === )
You can look at the official readme.txt

review-wave-google-places-reviews/rw_gplaces.php 92% from 13 tests

"Review Wave - Google Places Reviews" version 1.4.7's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("review-wave-google-places-reviews.php" instead of "rw_gplaces.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected1,070 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP5238331,023
CSS10028
JavaScript16019

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.31
Average class complexity29.00
▷ Minimum class complexity1.00
▷ Maximum class complexity85.00
Average method complexity4.11
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods45
▷ Static methods00.00%
▷ Public methods4191.11%
▷ Protected methods12.22%
▷ Private methods36.67%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.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
6 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
css/rating_color.png0.51KB0.38KB▼ 26.44%
css/location.png3.72KB2.45KB▼ 34.16%
star.png0.73KB0.62KB▼ 14.94%
css/rating_gray.png0.50KB0.37KB▼ 26.23%
css/person.png2.65KB1.66KB▼ 37.56%