62% quentn-wp

Code Review | Quentn WP

WordPress plugin Quentn WP scored 62% from 54 tests.

About plugin

  • Plugin page: quentn-wp
  • Plugin version: 1.2.7
  • PHP compatiblity: 5.6.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6.0-6.3
  • WordPress version: 6.3.1
  • First release: May 20, 2020
  • Latest release: Aug 28, 2023
  • Number of updates: 51
  • Update frequency: every 23.5 days
  • Top authors: quentn (100%)

Code review

54 tests

User reviews

1 review

Install metrics

500+ active / 9,521 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲1.37MB] [CPU: ▲4.63ms] Passed 4 tests

Server-side resources used by Quentn WP
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /4.98 ▲1.5254.22 ▲3.89
Dashboard /wp-admin4.62 ▲1.3260.55 ▲12.76
Posts /wp-admin/edit.php4.66 ▲1.3053.20 ▼1.79
Add New Post /wp-admin/post-new.php7.60 ▲1.71100.23 ▲4.16
Media Library /wp-admin/upload.php4.56 ▲1.3349.80 ▲12.27
Integration /wp-admin/admin.php?page=quentn-dashboard4.4941.85
Access /wp-admin/admin.php?page=quentn-page-access-overview4.5844.25
Access Restrictions /wp-admin/admin.php?page=quentn-access-pages-restrictions4.5343.18

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 395 new files
Database: 2 new tables, 7 new options
New tables
wp_qntn_restrictions
wp_qntn_user_data
New WordPress options
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-comments
quentn_db_version

Browser metrics Passed 4 tests

An overview of browser requirements for Quentn WP
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,924 ▲17814.04 ▼0.527.37 ▲5.2442.51 ▼1.79
Dashboard /wp-admin2,228 ▲435.99 ▲1.12106.33 ▲3.4685.32 ▲44.18
Posts /wp-admin/edit.php2,139 ▲502.51 ▲0.4637.23 ▼3.9635.48 ▼2.64
Add New Post /wp-admin/post-new.php1,583 ▲6423.75 ▲0.62640.83 ▼33.0137.88 ▼16.48
Media Library /wp-admin/upload.php1,433 ▲424.33 ▲0.05101.21 ▼2.7545.78 ▼5.47
Integration /wp-admin/admin.php?page=quentn-dashboard9042.3739.7244.74
Access /wp-admin/admin.php?page=quentn-page-access-overview1,0722.3535.0129.50
Access Restrictions /wp-admin/admin.php?page=quentn-access-pages-restrictions1,0722.3933.5826.42

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These errors were triggered by the plugin
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=quentn-page-access-overview
    • > Notice in wp-content/plugins/quentn-wp/includes/class-quentn-wp-access-overview-list.php+478
    Undefined index: page_id

SRP 0% 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
Please fix the following
  • 3× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/quentn-wp/admin/partials/quentn-wp-admin-display.php
    • > /wp-content/plugins/quentn-wp/public/partials/quentn-wp-public-display.php
    • > /wp-content/plugins/quentn-wp/vendor/mustache/mustache/bin/build_bootstrap.php
  • 121× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Interface 'QuentnWPGuzzleHttp\\Promise\\PromisorInterface' not found in wp-content/plugins/quentn-wp/vendor/guzzlehttp/guzzle/src/Pool.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'QuentnWPGuzzleHttp\\Cookie\\CookieJar' not found in wp-content/plugins/quentn-wp/vendor/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Mustache_Test_SpecTestCase' not found in wp-content/plugins/quentn-wp/vendor/mustache/mustache/test/Mustache/Test/FiveThree/Functional/MustacheSpecTest.php:18
    • > PHP Fatal error
      Uncaught Error: Interface 'QuentnWPGuzzleHttp\\Promise\\PromisorInterface' not found in wp-content/plugins/quentn-wp/vendor/guzzlehttp/promises/src/EachPromise.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'Quentn\\Client\\AbstractQuentnClient' not found in wp-content/plugins/quentn-wp/vendor/quentn/php-sdk/src/Client/OAuthClient.php:9
    • > PHP Fatal error
      require(): Failed opening required 'wp-content/plugins/quentn-wp/vendor/quentn/php-sdk/examples./vendor/autoload.php' (include_path='.:/usr/share/php') in wp-content/plugins/quentn-wp/vendor/quentn/php-sdk/examples/custom-field-examples.php on line 2
    • > PHP Fatal error
      Uncaught Error: Class 'Mustache_Test_FunctionalTestCase' not found in wp-content/plugins/quentn-wp/vendor/mustache/mustache/test/Mustache/Test/Cache/FilesystemCacheTest.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/quentn-wp/vendor/mustache/mustache/test/Mustache/Test/Exception/UnknownHelperExceptionTest.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/quentn-wp/vendor/mustache/mustache/test/Mustache/Test/HelperCollectionTest.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/quentn-wp/vendor/mustache/mustache/test/Mustache/Test/Loader/ArrayLoaderTest.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
9 plugin tags: page restriction, elementor integration, quentn, marketing automation, email marketing tool...

quentn-wp/quentn-wp.php 92% from 13 tests

The principal PHP file in "Quentn WP" v. 1.2.7 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Description: Please keep the plugin description shorter than 140 characters (currently 267 characters long)

Code Analysis 5% from 3 tests

File types 0% from 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Almost there! Just fix the following issues
  • For security reasons, never distribute binary or executable files with your plugin
    • .ms - Maxwell Script in Maxwell Render
      • wp-content/plugins/quentn-wp/vendor/mustache/mustache/test/fixtures/templates/alpha.ms
      • wp-content/plugins/quentn-wp/vendor/mustache/mustache/test/fixtures/templates/beta.ms
36,290 lines of code in 338 files:
LanguageFilesBlank linesComment linesLines of code
PHP2444,02810,54318,419
CSS1221110411,646
Markdown141,18403,540
JavaScript16281861,274
JSON900618
PO File1135152299
SVG100288
Mustache3610145
YAML26028
XML22024
make1409

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity9.19
▷ Minimum class complexity1.00
▷ Maximum class complexity94.00
Average method complexity2.45
▷ Minimum method complexity1.00
▷ Maximum method complexity31.00
Code structure
Namespaces12
Interfaces21
Traits2
Classes213
▷ Abstract classes62.82%
▷ Concrete classes20797.18%
▷ Final classes83.86%
Methods1,370
▷ Static methods1158.39%
▷ Public methods1,16484.96%
▷ Protected methods241.75%
▷ Private methods18213.28%
Functions185
▷ Named functions6132.97%
▷ Anonymous functions12467.03%
Constants129
▷ Global constants64.65%
▷ Class constants12395.35%
▷ Public constants123100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
admin/images/icon.png0.58KB0.60KB0.00%