DesarrollosWeb/documentofacil

View on GitHub

Showing 7 of 464 total issues

File Procedure.php has 271 lines of code (exceeds 250 allowed). Consider refactoring.
Open

<?php
 
//region Includes
include_once 'vendor/autoload.php';
include_once "Db.php";
Severity: Minor
Found in gestoria/Procedure.php - About 2 hrs to fix

File pago_en_linea.php has 268 lines of code (exceeds 250 allowed). Consider refactoring.
Confirmed

<?php
//region Includes
include_once 'gestoria/constants.php';
include_once 'gestoria/Procedure.php';
include_once 'gestoria/Db.php';
Severity: Minor
Found in pago_en_linea.php - About 2 hrs to fix

Method get_order_and_procedure has 41 lines of code (exceeds 25 allowed). Consider refactoring.
Open

public function get_order_and_procedure(string $procedure_id): array
{
$procedure_data = $this->db->get_query("select p.id,
creation_date,
update_date,
Severity: Minor
Found in gestoria/Procedure.php - About 1 hr to fix

Method process has 32 lines of code (exceeds 25 allowed). Consider refactoring.
Open

public function process(array $post, array $files): array
{
if (IS_DEVELOPMENT) {
krumo($post);
krumo($files);
Severity: Minor
Found in gestoria/Procedure.php - About 1 hr to fix

Method get_orders_current_user has 27 lines of code (exceeds 25 allowed). Consider refactoring.
Open

public function get_orders_current_user(array $limit = ["start" => 0, "items" => 10]): array
{
$user_type = $this->get_user_type($this->email);
$params = [];
if (isset($user_type["rol"]["administrator"])) {
Severity: Minor
Found in gestoria/Procedure.php - About 1 hr to fix

Function process has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
Open

public function process(array $post, array $files): array
{
if (IS_DEVELOPMENT) {
krumo($post);
krumo($files);
Severity: Minor
Found in gestoria/Procedure.php - About 45 mins to fix

Function get_user_type has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
Open

public function get_user_type(string $email): array
{
if (empty($email)) {
$email = $this->email;
}
Severity: Minor
Found in gestoria/Procedure.php - About 25 mins to fix
Severity
Category
Status
Source
Language