84% og-tags

Code Review | OG Tags

WordPress plugin OG Tags scored84%from 54 tests.

About plugin

  • Plugin page: og-tags
  • Plugin version: 2.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-5.8
  • WordPress version: 6.3.1
  • First release: Dec 29, 2013
  • Latest release: Aug 14, 2021
  • Number of updates: 18
  • Update frequency: every 154.7 days
  • Top authors: mariovalney (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

2,000+ active /39,132 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼5.60ms] Passed 4 tests

An overview of server-side resources used by OG Tags
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0840.57 ▼4.17
Dashboard /wp-admin3.38 ▲0.0850.59 ▲1.73
Posts /wp-admin/edit.php3.49 ▲0.1449.36 ▲0.12
Add New Post /wp-admin/post-new.php5.96 ▲0.0791.59 ▼15.72
Media Library /wp-admin/upload.php3.30 ▲0.0736.08 ▼2.64
OG Tags /wp-admin/options-general.php?page=og-tags-options3.3541.40

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 11 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
ogtags_options

Browser metrics Passed 4 tests

Checking browser requirements for OG Tags
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,820 ▲4913.68 ▼0.701.67 ▼0.4641.57 ▼4.12
Dashboard /wp-admin2,210 ▲694.82 ▼0.87100.73 ▲0.2839.36 ▼4.38
Posts /wp-admin/edit.php2,093 ▲42.03 ▲0.0239.58 ▼3.3735.66 ▼3.84
Add New Post /wp-admin/post-new.php1,533 ▼023.45 ▲0.27666.30 ▲48.3258.65 ▼1.73
Media Library /wp-admin/upload.php1,389 ▲14.28 ▲0.0893.81 ▼29.9144.52 ▼5.20
OG Tags /wp-admin/options-general.php?page=og-tags-options1,3154.6498.4942.47

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
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
  • 4× PHP files output text when accessed directly:
    • > /wp-content/plugins/og-tags/og-tags.php
    • > /wp-content/plugins/og-tags/modules/dashboard/class-og-tags-dashboard.php
    • > /wp-content/plugins/og-tags/modules/dashboard/admin/dashboard.php
    • > /wp-content/plugins/og-tags/modules/front/class-og-tags-front.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 97% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: Screenshot #1 (OG Tags - Dashboard) image required
You can take inspiration from this readme.txt

og-tags/og-tags.php Passed 13 tests

The main PHP file in "OG Tags" ver. 2.0.2 adds more information about the plugin and also serves as the entry point for this plugin
65 characters long description:
A plugin for optimization of Open Graph Tags for WordPress sites.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
There were no executable files found in this plugin622 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP4182334394
PO File14248121
CSS117085
JavaScript19422

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity8.67
▷ Minimum class complexity6.00
▷ Maximum class complexity14.00
Average method complexity1.74
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods31
▷ Static methods00.00%
▷ Public methods1858.06%
▷ Protected methods00.00%
▷ Private methods1341.94%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants466.67%
▷ Class constants233.33%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin