10% wpconnect

Code Review | WPConnect

WordPress plugin WPConnect scored10%from 54 tests.

About plugin

  • Plugin page: wpconnect
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-3.6
  • WordPress version: 6.3.1
  • First release: Aug 14, 2013
  • Latest release: Aug 15, 2013
  • Number of updates: 4
  • Update frequency: every 0.3 days
  • Top authors: modemlooper (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /996 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The following installer errors require your attention
  • This plugin did not install gracefully
    • > Notice in wp-content/plugins/wpconnect/includes/wpconnect-button.php+23
    Trying to access array offset on value of type bool

Server metrics [RAM: ▼1.93MB] [CPU: ▼52.52ms] Passed 4 tests

Server-side resources used by WPConnect
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.06 ▼1.406.08 ▼38.02
Dashboard /wp-admin2.08 ▼1.237.29 ▼41.76
Posts /wp-admin/edit.php2.08 ▼1.286.84 ▼45.61
Add New Post /wp-admin/post-new.php2.08 ▼3.817.02 ▼84.67
Media Library /wp-admin/upload.php2.08 ▼1.158.05 ▼29.75
WPConnect /wp-admin/options-general.php?page=wpconnect2.08204.04

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for WPConnect
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.35 ▼0.001.68 ▼0.0742.55 ▼7.28
Dashboard /wp-admin2,199 ▲225.57 ▼0.0687.49 ▼1.1840.04 ▼1.60
Posts /wp-admin/edit.php2,107 ▲42.01 ▼0.1339.44 ▲1.7835.34 ▼3.44
Add New Post /wp-admin/post-new.php1,528 ▲222.09 ▼1.45668.16 ▼39.5459.72 ▲5.21
Media Library /wp-admin/upload.php1,401 ▲14.15 ▼0.14100.49 ▼5.9045.21 ▲1.15
WPConnect /wp-admin/options-general.php?page=wpconnect8142.0024.4730.48

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • This plugin did not uninstall without warnings or errors
    • > Notice in wp-content/plugins/wpconnect/includes/wpconnect-button.php+23
    Trying to access array offset on value of type bool
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
    • > GET request to /wp-admin/options-general.php?page=wpconnect
    • > Notice in wp-content/plugins/wpconnect/includes/wpconnect-button.php+23
    Trying to access array offset on value of type bool

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
Please fix the following items
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/wpconnect/includes/wpconnect-button.php:22
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/wpconnect/includes/wpconnect-admin.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
3 plugin tags: log in, connect, sign in

wpconnect/loader.php 85% from 13 tests

The primary PHP file in "WPConnect" version 0.1 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Domain Path: The domain path folder was not found ("/languages/")
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("wpconnect.php" instead of "loader.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin168 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP49635168

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity8.00
▷ Minimum class complexity8.00
▷ Maximum class complexity8.00
Average method complexity2.75
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods125.00%
▷ Protected methods00.00%
▷ Private methods375.00%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants7
▷ Global constants7100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
PNG images were not found in this plugin