10% deweys-open-graph-helper

Code Review | Dewey's Open Graph Helper

WordPress plugin Dewey's Open Graph Helper scored10%from 54 tests.

About plugin

  • Plugin page: deweys-open-graph...
  • Plugin version: 2.0.4
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.1-4.5
  • WordPress version: 6.3.1
  • First release: Apr 23, 2015
  • Latest release: Dec 3, 2016
  • Number of updates: 13
  • Update frequency: every 71.5 days
  • Top authors: whatadewitt (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,087 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
You still need to fix the following installer errors
  • This plugin did not install gracefully
    • > Warning in wp-includes/class-wp-hook.php+310
    call_user_func_array() expects parameter 1 to be a valid callback, class 'WADOpenGraph' does not have a method 'activate'

Server metrics [RAM: ▼0.67MB] [CPU: ▼19.95ms] Passed 4 tests

A check of server-side resources used by Dewey's Open Graph Helper
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0340.09 ▲0.23
Dashboard /wp-admin3.34 ▼0.0049.35 ▼8.39
Posts /wp-admin/edit.php3.39 ▲0.0347.24 ▼5.27
Add New Post /wp-admin/post-new.php3.13 ▼2.7636.06 ▼66.38
Media Library /wp-admin/upload.php3.26 ▲0.0340.78 ▲5.74

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
db_upgraded
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Dewey's Open Graph Helper
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,824 ▲6314.38 ▲0.031.98 ▲0.4444.49 ▲3.15
Dashboard /wp-admin2,192 ▲205.50 ▼0.2383.38 ▼18.7938.88 ▼5.38
Posts /wp-admin/edit.php2,100 ▼01.97 ▼0.0237.47 ▼1.0931.67 ▼4.27
Add New Post /wp-admin/post-new.php1,526 ▼022.95 ▲0.05670.55 ▼20.1356.72 ▲1.45
Media Library /wp-admin/upload.php1,397 ▼34.19 ▼0.02101.53 ▼0.6343.72 ▼5.87

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Uninstall procedure validation failed for this plugin
    • > Warning in wp-includes/class-wp-hook.php+310
    call_user_func_array() expects parameter 1 to be a valid callback, class 'WADOpenGraph' does not have a method 'deactivate'
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/deweys-open-graph-helper/templates/ogform.php
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Notice
      Undefined variable: og_desc in wp-content/plugins/deweys-open-graph-helper/templates/ogform.php on line 23
    • > PHP Notice
      Undefined variable: og_type in wp-content/plugins/deweys-open-graph-helper/templates/ogform.php on line 28
    • > PHP Notice
      Undefined variable: og_title in wp-content/plugins/deweys-open-graph-helper/templates/ogform.php on line 18

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% 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
4 plugin tags: facebook, open graph, sharing, social

deweys-open-graph-helper/wad_open_graph.php 85% from 13 tests

The main file in "Dewey's Open Graph Helper" v. 2.0.4 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("deweys-open-graph-helper.php" instead of "wad_open_graph.php")
  • Text Domain: The text domain should only use lowercase characters and dashes

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
Good job! No executable or dangerous file extensions detected160 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP548130153
CSS1007

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity21.00
▷ Minimum class complexity21.00
▷ Maximum class complexity21.00
Average method complexity3.50
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods8
▷ Static methods225.00%
▷ Public methods787.50%
▷ Protected methods00.00%
▷ Private methods112.50%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
There are no PNG files in this plugin