84% wp-fragmention

Code Review | WP Fragmention

WordPress plugin WP Fragmention scored84%from 54 tests.

About plugin

  • Plugin page: wp-fragmention
  • Plugin version: 0.1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 2.7-4.3
  • WordPress version: 6.3.1
  • First release: Apr 25, 2014
  • Latest release: Aug 15, 2015
  • Number of updates: 17
  • Update frequency: every 28.1 days
  • Top authors: cconover (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,013 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼11.78ms] Passed 4 tests

Server-side resources used by WP Fragmention
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.32 ▼5.20
Dashboard /wp-admin3.32 ▼0.0243.85 ▼19.36
Posts /wp-admin/edit.php3.37 ▲0.0248.60 ▲3.70
Add New Post /wp-admin/post-new.php5.90 ▲0.0280.96 ▼26.27
Media Library /wp-admin/upload.php3.24 ▲0.0236.69 ▲5.28

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 6 new files
Database: no new tables, 7 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
widget_recent-comments
cc_fragmention_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for WP Fragmention
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,885 ▲13914.00 ▼0.425.10 ▲3.4838.00 ▼3.36
Dashboard /wp-admin2,206 ▲216.03 ▲1.13102.69 ▲1.0839.85 ▼3.13
Posts /wp-admin/edit.php2,089 ▼01.98 ▼0.0239.64 ▲3.5034.47 ▼2.03
Add New Post /wp-admin/post-new.php1,514 ▼617.60 ▼5.54634.63 ▲7.1151.16 ▼15.01
Media Library /wp-admin/upload.php1,388 ▲64.28 ▲0.0296.25 ▼0.9742.00 ▼1.33

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget

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× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function cconover\\get_option() in wp-content/plugins/wp-fragmention/wp-fragmention.php:33

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
3 plugin tags: link, javascript, fragmention

wp-fragmention/wp-fragmention.php Passed 13 tests

The principal PHP file in "WP Fragmention" v. 0.1.4 is loaded by WordPress automatically on each request
47 characters long description:
Add support for Fragmention links to WordPress.

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
Everything looks great! No dangerous files found in this plugin304 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript34469230
PHP1215269
CSS1015

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity7.00
▷ Minimum class complexity7.00
▷ Maximum class complexity7.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods00.00%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants00.00%
▷ Class constants5100.00%
▷ Public constants5100.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 files were detected