53% pronosticos-apuestas-tap

Code Review | Pronosticos Apuestas TAP

WordPress plugin Pronosticos Apuestas TAP scored53%from 54 tests.

About plugin

  • Plugin page: pronosticos-apues...
  • Plugin version: 1.2.6
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.1-4.4
  • WordPress version: 6.3.1
  • First release: Sep 7, 2015
  • Latest release: Jan 5, 2016
  • Number of updates: 16
  • Update frequency: every 7.5 days
  • Top authors: todoapuestas (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,091 total downloads

Benchmarks

Plugin footprint 48% 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.10MB] [CPU: ▼38.89ms] Passed 4 tests

A check of server-side resources used by Pronosticos Apuestas TAP
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /4.02 ▲0.5646.88 ▲8.80
Dashboard /wp-admin3.87 ▲0.5624.12 ▼29.56
Posts /wp-admin/edit.php3.87 ▲0.5121.73 ▼32.78
Add New Post /wp-admin/post-new.php3.87 ▼2.0223.64 ▼79.53
Media Library /wp-admin/upload.php3.87 ▲0.6421.50 ▼13.67
Suscripciones /wp-admin/admin.php?page=pronosticos-apuestas-tap/suscripciones3.8721.67
Ajustes /wp-admin/admin.php?page=pronosticos-apuestas-tap3.8723.80

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 138 new files
Database: 2 new tables, 12 new options
New tables
tapa_suscripcion
tapa_pedido
New WordPress options
PRONOSTICO_APUESTAS_PAGINA_PAYPAL_PAGO_CANCELADO
widget_recent-comments
PRONOSTICO_APUESTAS_PROMOCION
theysaidso_admin_options
PRONOSTICO_APUESTAS_METODOS_PAGO
PRONOSTICO_APUESTAS_PAGINA_CARRITO
db_upgraded
PRONOSTICO_APUESTAS_PAGINA_PAYPAL_PAGO_ACEPTADO
PRONOSTICO_APUESTAS_PAGINA_SOPORTE
widget_theysaidso_widget
...

Browser metrics Passed 4 tests

Pronosticos Apuestas TAP: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,955 ▲19414.44 ▲0.092.26 ▲0.2740.72 ▼0.69
Dashboard /wp-admin2,361 ▲1846.18 ▲0.56111.22 ▲7.8139.43 ▼7.61
Posts /wp-admin/edit.php2,286 ▲1863.30 ▲1.3349.98 ▲6.6436.31 ▼1.31
Add New Post /wp-admin/post-new.php1,579 ▲5323.55 ▼0.10676.75 ▼53.9735.26 ▼22.19
Media Library /wp-admin/upload.php1,429 ▲264.17 ▼0.0482.93 ▼14.4641.93 ▲0.98
Suscripciones /wp-admin/admin.php?page=pronosticos-apuestas-tap/suscripciones1,3393.8184.3041.30
Ajustes /wp-admin/admin.php?page=pronosticos-apuestas-tap1,6093.2752.6726.89

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • The plugin did not uninstall gracefully
    • > Warning in wp-content/plugins/pronosticos-apuestas-tap/admin/includes/cmb/init.php+748
    count(): Parameter must be an array or an object that implements Countable
  • The uninstall procedure failed, leaving 2 tables in the database
    • tapa_pedido
    • tapa_suscripcion
  • The uninstall procedure has failed, leaving 8 options in the database
    • widget_recent-comments
    • PRONOSTICO_APUESTAS_PROMOCION
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • PRONOSTICO_APUESTAS_METODOS_PAGO
    • can_compress_scripts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Almost there, just fix the following server-side errors
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pronosticos-apuestas-tap
    • > Warning in wp-content/plugins/pronosticos-apuestas-tap/admin/includes/cmb/init.php+748
    count(): Parameter must be an array or an object that implements Countable

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 take a closer look at the following
  • 2× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/pronosticos-apuestas-tap/public/views/public.php
    • > /wp-content/plugins/pronosticos-apuestas-tap/admin/includes/cmb/tests/phpunit/includes/bootstrap.php
  • 26× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_errors() in wp-content/plugins/pronosticos-apuestas-tap/admin/views/suscripciones-delete.php:5
    • > PHP Fatal error
      Uncaught Error: Interface 'PronosticosApuestasTAP\\Common\\BaseRepositoryInterface' not found in wp-content/plugins/pronosticos-apuestas-tap/includes/AbstractRepository.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'PronosticosApuestasTAP\\Common\\AbstractRepository' not found in wp-content/plugins/pronosticos-apuestas-tap/includes/PedidoRepository.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_errors() in wp-content/plugins/pronosticos-apuestas-tap/admin/views/suscripciones-fixed-records.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/pronosticos-apuestas-tap/public/views/shopping-cart-step-pago.php:23
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/pronosticos-apuestas-tap/public/views/shopping-cart-step-paysafecard.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'PronosticosApuestasTAP\\Common\\AbstractRepository' not found in wp-content/plugins/pronosticos-apuestas-tap/includes/UsuarioRepository.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/pronosticos-apuestas-tap/public/views/shopping-cart-invalid.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'PronosticosApuestasTAP\\Common\\AbstractRepository' not found in wp-content/plugins/pronosticos-apuestas-tap/includes/SuscripcionRepository.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/pronosticos-apuestas-tap/public/views/paypal-response-success.php:2

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 Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
4 plugin tags: tipsters, apuestas, picks, pronosticos

pronosticos-apuestas-tap/pronosticos-apuestas-tap.php Passed 13 tests

"Pronosticos Apuestas TAP" version 1.2.6's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
45 characters long description:
Plugin para gestionar pronosticos de apuestas

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin16,967 lines of code in 80 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript172,2707,3298,559
PHP441,0492,0026,254
CSS122111211,741
Markdown3880288
Bourne Shell115459
JSON10031
YAML15018
XML10117

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity28.36
▷ Minimum class complexity1.00
▷ Maximum class complexity136.00
Average method complexity3.03
▷ Minimum method complexity1.00
▷ Maximum method complexity35.00
Code structure
Namespaces5
Interfaces1
Traits0
Classes21
▷ Abstract classes14.76%
▷ Concrete classes2095.24%
▷ Final classes00.00%
Methods298
▷ Static methods5317.79%
▷ Public methods27792.95%
▷ Protected methods72.35%
▷ Private methods144.70%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants16
▷ Global constants212.50%
▷ Class constants1487.50%
▷ Public constants14100.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
39 PNG files occupy 0.06MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/includes/cmb/images/ui-bg_glass_75_dadada_1x400.png0.11KB0.16KB0.00%
admin/assets/images/sort_desc_disabled.png1.02KB0.25KB▼ 75.98%
admin/assets/images/sort_desc.png1.10KB0.25KB▼ 77.73%
admin/includes/cmb/images/ui-icons_888888_256x240.png5.23KB4.11KB▼ 21.49%
admin/assets/css/images/ui-bg_glass_65_ffffff_1x400.png0.10KB0.10KB▼ 5.71%