84% opengraphiq-lite

Code Review | OpenGraphiq Lite

WordPress plugin OpenGraphiq Lite scored84%from 54 tests.

About plugin

  • Plugin page: opengraphiq-lite
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.1
  • WordPress version: 6.3.1
  • First release: Nov 23, 2022
  • Latest release: Nov 23, 2022
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: boldthemes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /473 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.34MB] [CPU: ▼7.37ms] Passed 4 tests

Server-side resources used by OpenGraphiq Lite
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.79 ▲0.3344.16 ▼5.60
Dashboard /wp-admin3.64 ▲0.3455.62 ▲4.92
Posts /wp-admin/edit.php3.75 ▲0.4046.68 ▼12.28
Add New Post /wp-admin/post-new.php6.24 ▲0.3687.61 ▼9.84
Media Library /wp-admin/upload.php3.56 ▲0.3337.34 ▼1.74
All OG Templates /wp-admin/edit.php?post_type=opengraphiqtemplates3.6043.34
Add New /wp-admin/post-new.php?post_type=opengraphiqtemplates3.6247.44
Settings /wp-admin/edit.php?post_type=opengraphiqtemplates&page=opengraphiq_settings3.5738.07

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 49 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for OpenGraphiq Lite
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,847 ▲11213.35 ▼1.021.84 ▼0.7142.07 ▼8.89
Dashboard /wp-admin2,253 ▲624.84 ▼0.04114.87 ▲12.0042.39 ▼1.75
Posts /wp-admin/edit.php2,143 ▲572.06 ▲0.0434.61 ▼6.4635.44 ▼1.68
Add New Post /wp-admin/post-new.php1,560 ▲1524.29 ▲1.01684.56 ▲42.4662.06 ▼0.32
Media Library /wp-admin/upload.php1,432 ▲414.25 ▲0.0794.73 ▼2.4541.06 ▼1.83
All OG Templates /wp-admin/edit.php?post_type=opengraphiqtemplates1,1202.0233.2329.94
Add New /wp-admin/post-new.php?post_type=opengraphiqtemplates1,9725.6799.5436.07
Settings /wp-admin/edit.php?post_type=opengraphiqtemplates&page=opengraphiq_settings1,0483.1336.8027.76

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments

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 Passed 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
No output text or server-side errors detected on direct access of PHP files

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There are user-side issues you should fix
    • > GET request to /wp-admin/edit.php?post_type=opengraphiqtemplates&page=opengraphiq_settings
    • > Intervention (severe) in unknown
    /wp-admin/post-new.php?post_type=opengraphiqtemplates - Blocked attempt to show a 'beforeunload' confirmation panel for a frame that never had a user gesture since its load. https://www.chromestatus.com/feature/5082396709879808

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed:
  • Tags: You are using too many tags: 12 tag instead of maximum 10
Please take inspiration from this readme.txt

opengraphiq-lite/opengraphiq-lite.php Passed 13 tests

This is the main PHP file of "OpenGraphiq Lite" version 1.0.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
79 characters long description:
Enables you to create Open Graph images for your pages and posts - Lite version

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
Success! There were no dangerous files found in this plugin11,474 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript71514737,407
CSS32121701,995
PHP104503151,546
XML1816526

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity56.40
▷ Minimum class complexity1.00
▷ Maximum class complexity217.00
Average method complexity5.12
▷ Minimum method complexity1.00
▷ Maximum method complexity43.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods66
▷ Static methods00.00%
▷ Public methods5075.76%
▷ Protected methods00.00%
▷ Private methods1624.24%
Functions5
▷ Named functions120.00%
▷ Anonymous functions480.00%
Constants2
▷ Global constants2100.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
3 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
demo/assets/logo-black-1.png0.57KB0.58KB0.00%
admin/resources/og-static-image.png13.72KB7.92KB▼ 42.26%
demo/assets/og-logo.png13.72KB7.92KB▼ 42.26%