94% grisha-gplus-gallery

Code Review | Grisha's GPlus Gallery Shortcode

WordPress plugin Grisha's GPlus Gallery Shortcode scored 94% from 54 tests.

About plugin

  • Plugin page: grisha-gplus-gallery
  • Plugin version: 4.3.1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.3.1
  • WordPress version: 5.8.1
  • First release: Dec 10, 2015
  • Latest release: Dec 12, 2015
  • Number of updates: 12
  • Update frequency: every 0.2 days
  • Top authors: Grigory Metlenko (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 956 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

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

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

Analyzing server-side resources used by Grisha's GPlus Gallery Shortcode
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.1329.99 ▲10.84
Dashboard /wp-admin3.07 ▲0.0142.56 ▼6.17
Posts /wp-admin/edit.php3.13 ▲0.0146.85 ▲2.65
Add New Post /wp-admin/post-new.php5.43 ▼0.0192.10 ▼565.04
Media Library /wp-admin/upload.php3.02 ▲0.0131.44 ▼2.57

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Grisha's GPlus Gallery Shortcode: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,703 ▲10716.04 ▲0.4310.52 ▲1.6149.75 ▼0.11
Dashboard /wp-admin2,967 ▲335.92 ▼0.05156.01 ▲14.21109.12 ▼12.32
Posts /wp-admin/edit.php2,736 ▼32.72 ▼0.0176.37 ▲11.8788.69 ▼10.34
Add New Post /wp-admin/post-new.php1,672 ▲17218.77 ▲0.11352.57 ▼19.17107.15 ▼5.62
Media Library /wp-admin/upload.php1,810 ▲35.01 ▼0.02142.85 ▲0.21121.44 ▲6.75

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
This plugin's uninstaller ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Please take a closer look at the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/grisha-gplus-gallery/grisha-gplus-gallery.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 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
7 plugin tags: google photos, photo albums, google plus, shortcode, picasa...

grisha-gplus-gallery/grisha-gplus-gallery.php Passed 13 tests

The principal PHP file in "Grisha's GPlus Gallery Shortcode" v. 4.3.1.2 is loaded by WordPress automatically on each request
94 characters long description:
Use shortcode to add Google Photos gallery to post or page. [gplus-gallery user="#" album="#"]

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
No dangerous file extensions were detected33 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP111033

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.47
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
There were not PNG files found in your plugin