10% find-my-library-widget

Code Review | Find My Library widget

WordPress plugin Find My Library widget scored10%from 54 tests.

About plugin

  • Plugin page: find-my-library-w...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.8
  • WordPress version: 6.3.1
  • First release: Feb 15, 2014
  • Latest release: Feb 15, 2014
  • Number of updates: 5
  • Update frequency: every 0.2 days
  • Top authors: FindMyLibrary (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /765 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
These installer errors require your attention
  • The plugin cannot be installed
    • > Deprecated in wp-content/plugins/find-my-library-widget/library-finder-widget.php+26
    Methods with the same name as their class will not be constructors in a future version of PHP; library_finder_widget has a deprecated constructor

Server metrics [RAM: ▼1.91MB] [CPU: ▼53.42ms] Passed 4 tests

Analyzing server-side resources used by Find My Library widget
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.07 ▼1.384.15 ▼33.23
Dashboard /wp-admin2.10 ▼1.217.53 ▼43.44
Posts /wp-admin/edit.php2.10 ▼1.266.13 ▼44.24
Add New Post /wp-admin/post-new.php2.10 ▼3.796.68 ▼92.75
Media Library /wp-admin/upload.php2.10 ▼1.135.30 ▼27.19

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 3 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
widget_recent-posts
widget_library_finder_widget
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

Find My Library widget: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.21 ▼1.194.83 ▲3.1839.81 ▼4.34
Dashboard /wp-admin2,206 ▲204.85 ▼0.13111.50 ▲3.2244.33 ▲0.02
Posts /wp-admin/edit.php2,089 ▼02.06 ▲0.0139.94 ▼4.2035.18 ▼0.59
Add New Post /wp-admin/post-new.php1,522 ▼1123.33 ▲0.21580.24 ▼79.0459.16 ▲8.78
Media Library /wp-admin/upload.php1,391 ▲34.23 ▼0.0595.75 ▼3.6341.32 ▼1.99

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
It is recommended to fix the following
  • The plugin did not uninstall gracefully
    • > Deprecated in wp-content/plugins/find-my-library-widget/library-finder-widget.php+26
    Methods with the same name as their class will not be constructors in a future version of PHP; library_finder_widget has a deprecated constructor
  • The uninstall procedure has failed, leaving 7 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • widget_library_finder_widget
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
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 fix the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/find-my-library-widget/library-finder-widget.php:26

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need your attention:
  • Screenshots: Add descriptions for screenshots #1, #2 in find-my-library-widget/assets to your readme.txt
  • Plugin Name: You should set the name of your plugin on the first line ( === find-my-library-widget === )
The official readme.txt might help

find-my-library-widget/library-finder-widget.php 92% from 13 tests

"Find My Library widget" version 1.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("find-my-library-widget.php" instead of "library-finder-widget.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin77 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1213177

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.09
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity2.25
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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 images were found in this plugin