84% wpm-floc

Code Review | Disable FLoC

WordPress plugin Disable FLoC scored84%from 54 tests.

About plugin

  • Plugin page: wpm-floc
  • Plugin version: 1.3.3
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.7
  • WordPress version: 6.3.1
  • First release: Apr 17, 2021
  • Latest release: Apr 24, 2021
  • Number of updates: 16
  • Update frequency: every 0.6 days
  • Top authors: wpmunich (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

90+ active /1,768 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.02MB] [CPU: ▼9.24ms] Passed 4 tests

This is a short check of server-side resources used by Disable FLoC
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0340.60 ▼1.05
Dashboard /wp-admin3.33 ▼0.0147.21 ▼13.48
Posts /wp-admin/edit.php3.45 ▲0.0943.62 ▲0.21
Add New Post /wp-admin/post-new.php5.92 ▲0.0380.57 ▼22.62
Media Library /wp-admin/upload.php3.26 ▲0.0333.96 ▲2.46

Server storage [IO: ▲0.06MB] [DB: ▲0.07MB] Passed 3 tests

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 26 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Disable FLoC
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.24 ▼1.134.60 ▲2.7144.62 ▲0.36
Dashboard /wp-admin2,206 ▲154.87 ▼0.99110.34 ▲4.5742.05 ▼3.25
Posts /wp-admin/edit.php2,089 ▼01.99 ▼0.0138.52 ▲1.7034.87 ▼0.68
Add New Post /wp-admin/post-new.php1,541 ▼123.13 ▲5.07643.48 ▲42.5754.79 ▼0.89
Media Library /wp-admin/upload.php1,391 ▲34.23 ▼0.0896.69 ▼0.6742.38 ▼0.37

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 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
Almost there! Just fix the following items
  • 6× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Interface 'WpMunich\\wpmfloc\\Component_Interface' not found in wp-content/plugins/wpm-floc/inc/Settings/Component.php:16
    • > PHP Fatal error
      Uncaught Error: Interface 'WpMunich\\wpmfloc\\Component_Interface' not found in wp-content/plugins/wpm-floc/inc/FLoCCheck/Component.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_cacheaction() in wp-content/plugins/wpm-floc/inc/WPSC/wpsc.php:16
    • > PHP Fatal error
      Uncaught Error: Interface 'WpMunich\\wpmfloc\\Component_Interface' not found in wp-content/plugins/wpm-floc/inc/WPSC/Component.php:14
    • > PHP Fatal error
      Uncaught Error: Interface 'WpMunich\\wpmfloc\\Component_Interface' not found in wp-content/plugins/wpm-floc/inc/FLoC/Component.php:16
    • > PHP Fatal error
      Uncaught Error: Interface 'WpMunich\\wpmfloc\\Component_Interface' not found in wp-content/plugins/wpm-floc/inc/i18n/Component.php:16

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
9 plugin tags: privacy, tracking, floc, google, cohorts...

wpm-floc/wpmfloc.php 92% from 13 tests

The principal PHP file in "Disable FLoC" v. 1.3.3 is loaded by WordPress automatically on each request
The following require your attention:
  • Main file name: The principal plugin file should be the same as the plugin slug ("wpm-floc.php" instead of "wpmfloc.php")

Code Analysis Passed 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
No dangerous file extensions were detected1,098 lines of code in 25 files:
LanguageFilesBlank linesComment linesLines of code
PHP233325711,020
JavaScript263978

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity9.69
▷ Minimum class complexity1.00
▷ Maximum class complexity47.00
Average method complexity2.49
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces8
Interfaces2
Traits0
Classes11
▷ Abstract classes00.00%
▷ Concrete classes11100.00%
▷ Final classes00.00%
Methods80
▷ Static methods1518.75%
▷ Public methods7593.75%
▷ Protected methods22.50%
▷ Private methods33.75%
Functions7
▷ Named functions457.14%
▷ Anonymous functions342.86%
Constants4
▷ Global constants4100.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 files were detected