72% dublin-core-metadata-generator

Code Review | Dublin Core Metadata Generator

WordPress plugin Dublin Core Metadata Generator scored72%from 54 tests.

About plugin

  • Plugin page: dublin-core-metad...
  • Plugin version: 1.3.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.2.3-5.4.1
  • WordPress version: 6.3.1
  • First release: Oct 12, 2017
  • Latest release: May 19, 2020
  • Number of updates: 18
  • Update frequency: every 52.9 days
  • Top authors: Darken-x (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

1,000+ active /12,441 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.11MB] [CPU: ▼3.44ms] Passed 4 tests

A check of server-side resources used by Dublin Core Metadata Generator
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.87 ▼0.5922.47 ▼18.68
Dashboard /wp-admin3.35 ▲0.0548.47 ▲0.23
Posts /wp-admin/edit.php3.40 ▲0.0550.41 ▲4.10
Add New Post /wp-admin/post-new.php5.93 ▲0.0598.50 ▲4.76
Media Library /wp-admin/upload.php3.28 ▲0.0535.60 ▲0.61
Dublin Core Metadata Generator /wp-admin/options-general.php?page=dublincore_metadata_generator3.2433.32

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Dublin Core Metadata Generator
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲4713.17 ▼1.221.58 ▼0.4740.12 ▼2.87
Dashboard /wp-admin2,213 ▲225.85 ▼0.06104.11 ▼7.2943.69 ▼0.96
Posts /wp-admin/edit.php2,093 ▲221.99 ▼0.0335.44 ▼3.4638.86 ▲3.40
Add New Post /wp-admin/post-new.php1,537 ▲322.98 ▼0.14643.87 ▼45.4460.74 ▲2.83
Media Library /wp-admin/upload.php1,386 ▲14.23 ▼0.17100.50 ▼12.9541.12 ▼7.63
Dublin Core Metadata Generator /wp-admin/options-general.php?page=dublincore_metadata_generator1,0863.1538.6230.56

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following 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
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Please fix the following server-side errors
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=dublincore_metadata_generator
    • > Notice in wp-content/plugins/dublin-core-metadata-generator/dcmg_options.php+131
    Trying to access array offset on value of type bool

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 fix the following
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/dublin-core-metadata-generator/dcmg_metadata.php:19
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/dublin-core-metadata-generator/dcmg_options.php:2

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Please fix the following user-side errors
    • > GET request to /wp-admin/options-general.php?page=dublincore_metadata_generator
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1 1:28609 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/dublin-core-metadata-generator/js/dcmg-box-image.js?ver=6.3.1:4:31)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1:2:27292)" undefined
    • > GET request to /wp-admin/options-general.php?page=dublincore_metadata_generator
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1 1:28721 Uncaught TypeError: $(...).live is not a function

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 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
These attributes need your attention:
  • Tags: There are too many tags (11 tag instead of maximum 10)
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === dublin-core-metadata-generator === )
You can look at the official readme.txt

dublin-core-metadata-generator/dublin-core-metadata-generator.php Passed 13 tests

Analyzing the main PHP file in "Dublin Core Metadata Generator" version 1.3.2
81 characters long description:
Automatically generate Dublin Core and Open Graph metadata in your website pages.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected590 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP34228561
JavaScript10029

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.35
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%
Functions24
▷ Named functions24100.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
No PNG files were detected