67% teenvio-formulario-de-suscripcion

Code Review | Teenvio - Formulario de suscripci贸n

WordPress plugin Teenvio - Formulario de suscripci贸n scored67%from 54 tests.

About plugin

  • Plugin page: teenvio-formulari...
  • Plugin version: 1.2.3.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.9.8
  • WordPress version: 6.3.1
  • First release: Apr 20, 2017
  • Latest release: Oct 11, 2018
  • Number of updates: 10
  • Update frequency: every 54.0 days
  • Top authors: victorjchamorro (50%)teenvio (40%)davidmorenoisidro (30%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /6,076 total downloads

Benchmarks

Plugin footprint 65% 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.11MB] [CPU: ▼5.90ms] Passed 4 tests

An overview of server-side resources used by Teenvio - Formulario de suscripci贸n
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1144.76 ▲0.90
Dashboard /wp-admin3.42 ▲0.1247.36 ▼5.25
Posts /wp-admin/edit.php3.53 ▲0.1850.18 ▼3.41
Add New Post /wp-admin/post-new.php6.00 ▲0.1186.75 ▼15.83
Media Library /wp-admin/upload.php3.34 ▲0.1141.05 ▲3.48
TeSu Plugin /wp-admin/admin.php?page=tesu_plugin3.2834.72

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 23 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
widget_recent-comments
can_compress_scripts
widget_tesu_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Teenvio - Formulario de suscripci贸n
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,819 ▲3314.25 ▼0.001.83 ▼0.2043.17 ▼4.54
Dashboard /wp-admin2,228 ▲605.52 ▼0.0286.95 ▼15.7478.04 ▲30.02
Posts /wp-admin/edit.php2,137 ▲341.96 ▼0.0736.07 ▼5.8433.46 ▼4.63
Add New Post /wp-admin/post-new.php1,579 ▲5123.30 ▲0.30737.45 ▲62.5351.49 ▲0.72
Media Library /wp-admin/upload.php1,433 ▲304.19 ▼0.05100.14 ▼9.5880.49 ▲34.53
TeSu Plugin /wp-admin/admin.php?page=tesu_plugin9111.9226.2140.48

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • Uninstall procedure validation failed for this plugin
    • > Warning in wp-content/plugins/teenvio-formulario-de-suscripcion/tesu-admin.php+244
    Invalid argument supplied for foreach()
  • Zombie WordPress options were found after uninstall: 7 options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_tesu_widget
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests 50% 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)
Smoke test failed, please fix the following
  • 7 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=tesu_plugin
    • > Notice in wp-content/plugins/teenvio-formulario-de-suscripcion/tesu-admin.php+181
    Trying to access array offset on value of type bool

SRP 50% 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
Please fix the following items
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/teenvio-formulario-de-suscripcion/tesu-widget.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/teenvio-formulario-de-suscripcion/tesu-widget.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 83% from 29 tests

readme.txt 81% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Layer form contact (shown)), #2 (Layer form contact (hidden))
  • Donate link: Invalid URI found ("")
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === teenvio-formulario-de-suscripcion === )
You can take inspiration from this readme.txt

teenvio-formulario-de-suscripcion/tesu-admin.php 85% from 13 tests

"Teenvio - Formulario de suscripci贸n" version 1.2.3.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("teenvio-formulario-de-suscripcion.php" instead of "tesu-admin.php")
  • Text Domain: The text domain name must use dashes instead of underscores, and it must be lowercase

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin1,256 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP6221436996
PO File3750214
JavaScript18046

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity19.00
▷ Minimum class complexity1.00
▷ Maximum class complexity58.00
Average method complexity2.15
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods63
▷ Static methods00.00%
▷ Public methods6298.41%
▷ Protected methods00.00%
▷ Private methods11.59%
Functions23
▷ Named functions2295.65%
▷ Anonymous functions14.35%
Constants20
▷ Global constants00.00%
▷ Class constants20100.00%
▷ Public constants20100.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
3 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/teenvio_head.png2.99KB1.42KB▼ 52.57%
images/teenvio_20x20.png0.79KB0.74KB▼ 5.35%
images/teenvio.png1.33KB1.25KB▼ 6.52%