94% open-graph-link-tile

Code Review | Open Graph link tile

WordPress plugin Open Graph link tile scored 94% from 54 tests.

About plugin

  • Plugin page: open-graph-link-tile
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 2.6-4.2.2
  • WordPress version: 5.8.1
  • First release: Jul 14, 2015
  • Latest release: Jul 14, 2015
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: kotaroho (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 608 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼139.22ms] Passed 4 tests

This is a short check of server-side resources used by Open Graph link tile
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.87 ▲0.1533.96 ▲7.93
Dashboard /wp-admin3.10 ▲0.0444.11 ▼2.00
Posts /wp-admin/edit.php3.15 ▲0.0444.65 ▲0.40
Add New Post /wp-admin/post-new.php5.45 ▲0.0286.86 ▼556.16
Media Library /wp-admin/upload.php3.04 ▲0.0335.36 ▲0.90

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 4 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for Open Graph link tile
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,705 ▲10915.93 ▲0.279.29 ▲1.3448.36 ▼3.46
Dashboard /wp-admin2,967 ▲335.91 ▼0.06134.12 ▼2.34114.51 ▼2.12
Posts /wp-admin/edit.php2,739 ▼02.72 ▼0.0063.81 ▲1.6387.01 ▲5.91
Add New Post /wp-admin/post-new.php1,672 ▼418.89 ▲0.01363.69 ▼3.27116.32 ▲4.60
Media Library /wp-admin/upload.php1,810 ▲35.00 ▼0.03144.99 ▼3.74116.73 ▼1.31

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
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

SRP 50% 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
Almost there! Just fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/open-graph-link-tile/khlt_main.php:65

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
2 plugin tags: link, ogp

open-graph-link-tile/khlt_main.php 85% from 13 tests

The primary PHP file in "Open Graph link tile" version 1.0.0 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Description: Please don't use more than 140 characters for the plugin description (currently 154 characters long)
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("open-graph-link-tile.php" instead of "khlt_main.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected216 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP24091160
CSS10056

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.50
Average class complexity28.00
▷ Minimum class complexity28.00
▷ Maximum class complexity28.00
Average method complexity3.45
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods11
▷ Static methods218.18%
▷ Public methods1090.91%
▷ Protected methods00.00%
▷ Private methods19.09%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG images were found in this plugin