10% r12themes-quotes

Code Review | R12Themes Quotes

WordPress plugin R12Themes Quotes scored10%from 54 tests.

About plugin

  • Plugin page: r12themes-quotes
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.4.2
  • WordPress version: 6.3.1
  • First release: Nov 22, 2012
  • Latest release: Nov 22, 2012
  • Number of updates: 5
  • Update frequency: every 0.2 days
  • Top authors: rzvc (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /993 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
It is recommended to fix the following installer errors
  • The plugin did not install without errors
    • > Deprecated in wp-content/plugins/r12themes-quotes/classes/class-r12themes-widget-quotes.php+135
    Function create_function() is deprecated

Server metrics [RAM: ▼1.96MB] [CPU: ▼55.29ms] Passed 4 tests

An overview of server-side resources used by R12Themes Quotes
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.444.46 ▼35.30
Dashboard /wp-admin2.05 ▼1.265.53 ▼46.10
Posts /wp-admin/edit.php2.05 ▼1.315.77 ▼45.07
Add New Post /wp-admin/post-new.php2.05 ▼3.845.23 ▼94.70
Media Library /wp-admin/upload.php2.05 ▼1.185.56 ▼30.04
All Quotes /wp-admin/edit.php?post_type=quote2.054.53
Add New /wp-admin/post-new.php?post_type=quote2.056.05

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
db_upgraded
widget_recent-comments
widget_r12themes_quotes

Browser metrics Passed 4 tests

Checking browser requirements for R12Themes Quotes
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,844 ▲8314.28 ▼0.071.82 ▼0.2341.56 ▼5.91
Dashboard /wp-admin2,219 ▲455.57 ▼0.0597.71 ▲9.7842.40 ▲0.68
Posts /wp-admin/edit.php2,130 ▲272.03 ▲0.0234.55 ▼1.8830.01 ▼6.70
Add New Post /wp-admin/post-new.php1,550 ▲2223.08 ▲0.00655.25 ▼11.3855.32 ▼2.81
Media Library /wp-admin/upload.php1,424 ▲244.23 ▲0.06106.04 ▼0.2741.76 ▼2.06
All Quotes /wp-admin/edit.php?post_type=quote1,0971.9336.3631.09
Add New /wp-admin/post-new.php?post_type=quote2,1847.67169.1265.60

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • The plugin did not uninstall gracefully
    • > Deprecated in wp-content/plugins/r12themes-quotes/classes/class-r12themes-widget-quotes.php+135
    Function create_function() is deprecated
  • Zombie WordPress options detected upon uninstall: 7 options
    • widget_recent-comments
    • widget_r12themes_quotes
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These server-side errors were triggered
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=quote
    • > Deprecated in wp-content/plugins/r12themes-quotes/classes/class-r12themes-widget-quotes.php+135
    Function create_function() is deprecated
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=quote
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in R12Themes_Widget_Quotes is deprecated since version 4.3.0! Use __construct() instead.
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=quote
    • > Notice in wp-includes/class-wp-post-type.php+652
    Array to string conversion

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

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

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
Please fix the following attributes:
  • Screenshots: Screenshot #1 (The management screen in your WordPress admin panel) image not found
The official readme.txt is a good inspiration

r12themes-quotes/r12themes-quotes.php Passed 13 tests

"R12Themes Quotes" version 1.0.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
117 characters long description:
Hi, I`m an wordpress plugin that show your favorite quotes on your blog using our shortcode, widget sau template tag.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin301 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP486105288
CSS11313

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity13.00
▷ Minimum class complexity10.00
▷ Maximum class complexity16.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods12
▷ Static methods00.00%
▷ Public methods1191.67%
▷ Protected methods00.00%
▷ Private methods18.33%
Functions3
▷ Named functions3100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/quotes-icon.png3.07KB1.88KB▼ 38.95%