73% hire-me-widget

Code Review | Hire Me Widget

WordPress plugin Hire Me Widget scored73%from 54 tests.

About plugin

  • Plugin page: hire-me-widget
  • Plugin version: 1.0.5
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3
  • WordPress version: 6.3.1
  • First release: Dec 11, 2017
  • Latest release: Aug 9, 2023
  • Number of updates: 41
  • Update frequency: every 50.4 days
  • Top authors: nitin247 (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

40+ active /3,765 total downloads

Benchmarks

Plugin footprint 64% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲5.34MB] [CPU: ▲21.26ms] 50% from 4 tests

Server-side resources used by Hire Me Widget
It is recommended to improve the following
  • CPU: Total CPU usage must kept under 500.00ms (currently 1,593.36ms on /wp-admin/admin.php?page=hire-me-widget)
  • Extra RAM: Extra memory usage must be kept under 5MB (currently 5.34MB on /wp-admin/admin.php?page=hire-me-widget)
PageMemory (MB)CPU Time (ms)
Home /9.20 ▲5.7469.75 ▲27.81
Dashboard /wp-admin9.22 ▲5.8777.74 ▲13.73
Posts /wp-admin/edit.php9.22 ▲5.8678.52 ▲24.77
Add New Post /wp-admin/post-new.php9.79 ▲3.90115.33 ▲19.22
Media Library /wp-admin/upload.php9.22 ▲5.9965.24 ▲27.33
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius9.2266.23
Hire Me Widget /wp-admin/admin.php?page=hire-me-widget9.221,593.36

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 201 new files
Database: no new tables, 10 new options
New WordPress options
can_compress_scripts
widget_hire_me_widget
widget_recent-comments
fs_active_plugins
widget_theysaidso_widget
fs_debug_mode
theysaidso_admin_options
db_upgraded
widget_recent-posts
fs_accounts

Browser metrics Passed 4 tests

Checking browser requirements for Hire Me Widget
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,808 ▲7314.16 ▼0.211.79 ▼0.2129.51 ▼22.57
Dashboard /wp-admin2,209 ▲325.61 ▼0.0893.24 ▼5.2343.72 ▼2.78
Posts /wp-admin/edit.php2,121 ▲182.02 ▲0.0741.93 ▲0.2539.69 ▲3.85
Add New Post /wp-admin/post-new.php1,531 ▲222.14 ▼1.09679.79 ▲67.7852.81 ▼10.49
Media Library /wp-admin/upload.php1,420 ▲174.11 ▼0.04101.79 ▼0.7445.44 ▼0.51
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius1,0721.6929.1429.44
Hire Me Widget /wp-admin/admin.php?page=hire-me-widget9801.8324.0160.61

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/hire-me-widget/freemius/includes/class-freemius.php+8486
    Undefined property: stdClass::$plugins
  • This plugin does not fully uninstall, leaving 10 options in the database
    • db_upgraded
    • fs_accounts
    • fs_active_plugins
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_hire_me_widget
    • can_compress_scripts
    • fs_debug_mode
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

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
Please take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/hire-me-widget/inc/class-hire-me-widget.php:1

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that need to be fixed:
  • Tags: Please delete some tags, you are using 14 tag instead of maximum 10
  • Screenshots: A description for screenshot #1 is missing in hire-me-widget/assets to your readme.txt
Please take inspiration from this readme.txt

hire-me-widget/hire-me-widget.php Passed 13 tests

Analyzing the main PHP file in "Hire Me Widget" version 1.0.5
136 characters long description:
Effortlessly display if your team or you are available for hire using this widget. Useful for freelance developers or designers like me.

Code Analysis 97% from 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
Everything looks great! No dangerous files found in this plugin49,318 lines of code in 153 files:
LanguageFilesBlank linesComment linesLines of code
PHP1228,03017,33933,615
PO File126,9608,45515,240
Markdown1680214
JavaScript33459194
CSS149128
JSON10027

PHP code 50% from 2 tests

An overview of cyclomatic complexity and code structure
These items need your attention
  • Class cyclomatic complexity has to be reduced to less than 1000 (currently 3,073)
Cyclomatic complexity
Average complexity per logical line of code0.63
Average class complexity91.47
▷ Minimum class complexity1.00
▷ Maximum class complexity3,073.00
Average method complexity4.59
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes49
▷ Abstract classes24.08%
▷ Concrete classes4795.92%
▷ Final classes00.00%
Methods1,265
▷ Static methods19715.57%
▷ Public methods87669.25%
▷ Protected methods171.34%
▷ Private methods37229.41%
Functions104
▷ Named functions104100.00%
▷ Anonymous functions00.00%
Constants146
▷ Global constants9967.81%
▷ Class constants4732.19%
▷ Public constants47100.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
5 PNG files occupy 0.08MB with 0.04MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
freemius/assets/img/hire-me-widget.png10.84KB4.74KB▼ 56.24%
freemius/assets/img/wc-thanks-redirect.png23.38KB10.44KB▼ 55.36%
freemius/assets/img/wc-thanks-redirect-pro.png23.38KB10.44KB▼ 55.36%
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%