10% refgenerator

Code Review | RefGenerator

WordPress plugin RefGenerator scored10%from 54 tests.

About plugin

  • Plugin page: refgenerator
  • Plugin version: 2.3
  • PHP version: 7.4.16
  • WordPress compatibility: 2.6-3.3.1
  • WordPress version: 6.3.1
  • First release: Dec 8, 2008
  • Latest release: Apr 13, 2012
  • Number of updates: 12
  • Update frequency: every 101.9 days
  • Top authors: nyamsprod (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,874 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
You still need to fix the following installer errors
  • The plugin did not install without errors
    • > User deprecated in wp-includes/functions.php+5747
    Function load_plugin_textdomain was called with an argument that is deprecated since version 2.7.0 with no alternative available.

Server metrics [RAM: ▼1.93MB] [CPU: ▼54.00ms] Passed 4 tests

An overview of server-side resources used by RefGenerator
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.10 ▼1.415.20 ▼39.37
Dashboard /wp-admin2.12 ▼1.236.88 ▼45.75
Posts /wp-admin/edit.php2.12 ▼1.285.87 ▼42.33
Add New Post /wp-admin/post-new.php2.12 ▼3.816.19 ▼88.54
Media Library /wp-admin/upload.php2.12 ▼1.156.11 ▼30.20
RefGenerator /wp-admin/options-general.php?page=refgenerator/options-refgenerator.php2.128.25

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 10 new files
Database: no new tables, 13 new options
New WordPress options
refgen_display_settings
refgen_display_title
refgen_method
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
refgen_post_parent_id
refgen_post_links_class
...

Browser metrics Passed 4 tests

This is an overview of browser requirements for RefGenerator
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,799 ▲3814.27 ▲0.131.67 ▼0.5944.08 ▼3.19
Dashboard /wp-admin2,204 ▲275.64 ▲0.1292.57 ▼12.9640.39 ▼5.75
Posts /wp-admin/edit.php2,106 ▲92.06 ▲0.0936.56 ▼1.2831.62 ▼3.92
Add New Post /wp-admin/post-new.php1,533 ▲723.08 ▼0.04678.01 ▲21.5758.93 ▲5.52
Media Library /wp-admin/upload.php1,406 ▲34.18 ▼0.07107.96 ▲6.6748.96 ▲7.21
RefGenerator /wp-admin/options-general.php?page=refgenerator/options-refgenerator.php1,1142.0628.0644.18

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Uninstall procedure validation failed for this plugin
    • > User deprecated in wp-includes/functions.php+5747
    Function load_plugin_textdomain was called with an argument that is deprecated since version 2.7.0 with no alternative available.
  • Zombie WordPress options detected upon uninstall: 13 options
    • refgen_display_title
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • refgen_post_content_tag
    • widget_recent-comments
    • refgen_post_parent_id
    • refgen_display_settings
    • refgen_post_links_class
    • refgen_method
    • ...

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
These server-side errors were triggered
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=refgenerator/options-refgenerator.php
    • > User deprecated in wp-includes/functions.php+5747
    Function load_plugin_textdomain was called with an argument that is deprecated since version 2.7.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=refgenerator/options-refgenerator.php
    • > Notice in wp-content/plugins/refgenerator/options-refgenerator.php+47
    Undefined index: stage

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/refgenerator/refgenerator.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/refgenerator/options-refgenerator.php:24

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
3 plugin tags: links, posts, plugin

refgenerator/refgenerator.php 92% from 13 tests

This is the main PHP file of "RefGenerator" version 2.3, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Description: Keep the plugin description shorter than 140 characters (currently 272 characters long)

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
No dangerous file extensions were detected445 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP21630268
PO File14444101
JavaScript20043
CSS22033

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.36
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%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
PNG images were not found in this plugin