Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors
Server metrics [RAM: ▲0.48MB] [CPU: ▼4.83ms] Passed 4 tests
This is a short check of server-side resources used by Library Management System
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.92 ▲0.46 | 41.48 ▲3.76 |
Dashboard /wp-admin | 3.84 ▲0.50 | 49.70 ▼10.65 |
Posts /wp-admin/edit.php | 3.90 ▲0.54 | 45.83 ▼0.88 |
Add New Post /wp-admin/post-new.php | 6.36 ▲0.48 | 84.73 ▼8.35 |
Media Library /wp-admin/upload.php | 3.70 ▲0.47 | 40.07 ▲0.57 |
Issue Book /wp-admin/admin.php?page=owt-lib-create-book-issue | 3.66 | 34.78 |
Issued History /wp-admin/admin.php?page=owt-lib-book-issue-list | 3.70 | 34.29 |
Returned History /wp-admin/admin.php?page=owt-lib-return-book-list | 3.71 | 35.18 |
Settings Panel /wp-admin/admin.php?page=owt-lib-manage-settings | 3.88 | 34.12 |
/wp-admin/admin.php?page=owt-lib-create-user | 3.90 | 37.56 |
Dashboard /wp-admin/admin.php?page=owt-lib-manage | 3.72 | 36.15 |
Bookcase & Sections /wp-admin/admin.php?page=owt-lib-manage-bookcase | 3.71 | 34.23 |
Categories & Books /wp-admin/admin.php?page=owt-lib-manage-books | 3.72 | 34.66 |
Departments & Users /wp-admin/admin.php?page=owt-lib-manage-users | 3.71 | 31.31 |
Return Book /wp-admin/admin.php?page=owt-lib-create-book-return | 3.70 | 35.32 |
Server storage [IO: ▲7.95MB] [DB: ▲0.02MB] Passed 3 tests
Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 106 new files
Database: 14 new tables, 8 new options
New tables |
---|
wp_owt_lib_category |
wp_owt_lib_students |
wp_owt_lib_return_book |
wp_owt_lib_staff_type |
wp_owt_lib_currency_code |
wp_owt_lib_bookcase_sections |
wp_owt_lib_days_settings |
wp_owt_lib_books |
wp_owt_lib_branch |
wp_owt_lib_staffs |
... |
New WordPress options |
---|
db_upgraded |
widget_recent-posts |
owt_lib_book_late_fine |
widget_theysaidso_widget |
can_compress_scripts |
widget_recent-comments |
theysaidso_admin_options |
owt_lib_currency_code |
Browser metrics Passed 4 tests
An overview of browser requirements for Library Management System
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,973 ▲212 | 13.57 ▼1.06 | 10.61 ▲9.01 | 41.80 ▲3.50 |
Dashboard /wp-admin | 2,255 ▲81 | 5.52 ▼0.01 | 92.58 ▲8.69 | 43.69 ▲3.39 |
Posts /wp-admin/edit.php | 2,160 ▲60 | 2.00 ▲0.01 | 33.42 ▼2.99 | 34.34 ▼1.75 |
Add New Post /wp-admin/post-new.php | 1,572 ▲40 | 23.43 ▲0.28 | 679.62 ▲33.49 | 52.53 ▲3.89 |
Media Library /wp-admin/upload.php | 1,460 ▲66 | 4.17 ▼0.05 | 93.62 ▼4.29 | 42.42 ▼0.37 |
Issue Book /wp-admin/admin.php?page=owt-lib-create-book-issue | 1,083 | 6.53 | 174.07 | 79.83 |
Issued History /wp-admin/admin.php?page=owt-lib-book-issue-list | 1,086 | 5.46 | 170.45 | 26.35 |
Returned History /wp-admin/admin.php?page=owt-lib-return-book-list | 1,176 | 5.45 | 112.60 | 26.86 |
Settings Panel /wp-admin/admin.php?page=owt-lib-manage-settings | 1,652 | 6.50 | 102.37 | 28.59 |
/wp-admin/admin.php?page=owt-lib-create-user | 2,514 | 6.66 | 114.15 | 77.81 |
Dashboard /wp-admin/admin.php?page=owt-lib-manage | 1,234 | 6.45 | 95.57 | 47.29 |
Bookcase & Sections /wp-admin/admin.php?page=owt-lib-manage-bookcase | 1,201 | 5.59 | 111.28 | 24.58 |
Categories & Books /wp-admin/admin.php?page=owt-lib-manage-books | 1,225 | 5.42 | 108.06 | 27.41 |
Departments & Users /wp-admin/admin.php?page=owt-lib-manage-users | 1,174 | 5.42 | 106.51 | 24.37 |
Return Book /wp-admin/admin.php?page=owt-lib-create-book-return | 1,014 | 6.44 | 91.88 | 27.26 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
- This plugin does not fully uninstall, leaving 8 options in the database
- theysaidso_admin_options
- can_compress_scripts
- db_upgraded
- widget_recent-posts
- owt_lib_book_late_fine
- widget_theysaidso_widget
- owt_lib_currency_code
- widget_recent-comments
Smoke tests 25% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Almost there, just fix the following server-side errors
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=owt-lib-manage-settings
- > User notice in wp-includes/functions.php+5905
Function wpdb::prepare was called incorrectly. The query argument of wpdb::prepare() must have a placeholder. Please see Debugging in WordPress for more information. (This message was added in version 3.9.0.)
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=owt-lib-manage-settings
- > User notice in wp-includes/functions.php+5905
Function wpdb::prepare was called incorrectly. The query does not contain the correct number of placeholders (0) for the number of arguments passed (1). Please see Debugging in WordPress for more information. (This message was added in version 4.8.3.)
SRP 0% from 2 tests
🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Almost there! Just fix the following items
- 24× GET requests to PHP files return non-empty strings (only 10 are shown):
- > /wp-content/plugins/library-management-system/admin/views/book/tmpl-lms-books-list.php
- > /wp-content/plugins/library-management-system/admin/views/owt-lms-dashboard.php
- > /wp-content/plugins/library-management-system/admin/views/staff/owt-lms-create-staff.php
- > /wp-content/plugins/library-management-system/admin/views/book/owt-lms-create-book.php
- > /wp-content/plugins/library-management-system/admin/views/report/owt-lms-student-book-issue-list.php
- > /wp-content/plugins/library-management-system/admin/views/common.php
- > /wp-content/plugins/library-management-system/admin/views/report/owt-lms-book-return-list.php
- > /wp-content/plugins/library-management-system/public/views/owt-lms-frontend-tabs.php
- > /wp-content/plugins/library-management-system/admin/views/report/owt-lms-entry-return-book.php
- > /wp-content/plugins/library-management-system/admin/views/report/owt-lib-contact-details.php
- 103× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Warning
count(): Parameter must be an array or an object that implements Countable in wp-content/plugins/library-management-system/admin/views/staff/owt-lms-create-staff.php on line 50
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/library-management-system/admin/views/report/owt-lms-create-issue-book.php on line 63
- > PHP Warning
include_once(OWT_LIBRARY_PLUGIN_DIR_PATHadmin/views/common.php): failed to open stream: No such file or directory in wp-content/plugins/library-management-system/admin/views/book/owt-lms-create-book.php on line 23
- > PHP Warning
include_once(): Failed opening 'OWT_LIBRARY_PLUGIN_DIR_PATHadmin/views/common.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/library-management-system/admin/views/report/owt-lms-entry-return-book.php on line 13
- > PHP Warning
include_once(OWT_LIBRARY_PLUGIN_DIR_PATHadmin/views/common.php): failed to open stream: No such file or directory in wp-content/plugins/library-management-system/admin/views/book/owt-lms-books-list.php on line 13
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/library-management-system/admin/views/report/owt-lms-create-issue-book.php on line 33
- > PHP Warning
Use of undefined constant OWT_LIBRARY_PLUGIN_BOOK_CURRENCY - assumed 'OWT_LIBRARY_PLUGIN_BOOK_CURRENCY' (this will throw an Error in a future version of PHP) in wp-content/plugins/library-management-system/admin/views/report/owt-lms-book-return-list.php on line 96
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/library-management-system/admin/views/owt-lms-dashboard.php on line 26
- > PHP Warning
Use of undefined constant OWT_LIBRARY_PLUGIN_DIR_PATH - assumed 'OWT_LIBRARY_PLUGIN_DIR_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/library-management-system/admin/views/report/owt-lms-staff-book-return-list.php on line 12
- > PHP Notice
Undefined variable: params in wp-content/plugins/library-management-system/admin/views/report/owt-lms-create-issue-book.php on line 33
- > PHP Warning
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need your attention:
- Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line (
=== library-management-system ===
)
library-management-system/library-management-system.php 92% from 13 tests
The main PHP script in "Library Management System" version 2.0.0 is automatically included on every request by WordPress
The following require your attention:
- Description: Please don't use more than 140 characters for the plugin description (currently 274 characters long)
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin29,878 lines of code in 66 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
SVG | 6 | 1 | 3 | 13,301 |
CSS | 13 | 2,794 | 182 | 10,327 |
PHP | 35 | 764 | 531 | 5,077 |
JavaScript | 11 | 71 | 75 | 1,166 |
Markdown | 1 | 2 | 0 | 7 |
PHP code 50% from 2 tests
This is a very shot review of cyclomatic complexity and code structure
Please fix the following
- Cyclomatic complexity of methods has to be reduced to less than 100 (currently 265)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.50 |
Average class complexity | 51.00 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 306.00 |
Average method complexity | 5.79 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 265.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 7 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 7 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 73 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 68 | 93.15% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 5 | 6.85% |
Functions | 3 | |
▷ Named functions | 3 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 8 | |
▷ Global constants | 8 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
8 PNG files occupy 0.23MB with 0.09MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/images/teacher.png | 148.74KB | 58.46KB | ▼ 60.69% |
assets/images/blank-user.png | 18.84KB | 7.92KB | ▼ 57.97% |
assets/images/sort_asc.png | 0.16KB | 0.25KB | 0.00% |
assets/images/issue-return.png | 5.90KB | 4.75KB | ▼ 19.59% |
assets/images/student.png | 55.40KB | 25.88KB | ▼ 53.29% |