Showing 54 of 54 total issues
Method convertToUnicode
has 308 lines of code (exceeds 25 allowed). Consider refactoring. Open
function convertToUnicode($message)
{
$chrArray[0] = "،";
$unicodeArray[0] = "060C";
$chrArray[1] = "؛";
File CURL.php
has 487 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
namespace atmonshi\sender\STag;
class CURL
CURL
has 38 functions (exceeds 20 allowed). Consider refactoring. Open
class CURL
{
const VERSION = '2.1.0';
private $cookies = [];
Function get
has a Cognitive Complexity of 29 (exceeds 5 allowed). Consider refactoring. Open
public function get($url_mixed, $data = [])
{
if (is_array($url_mixed)) {
$curl_multi = curl_multi_init();
$this->multi_parent = true;
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
File fsockopen.php
has 320 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
//دالة فحص حالة الإرسال بإستخدام بوابة fsockopen
function sendStatus($viewResult=1)
{
global $arraySendStatus;
File functionUnicode.php
has 313 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
//دالة تحويل الرساله إلى ترميز UNICODE الخاص بالإرسال من خلال بوابة موبايلي
function convertToUnicode($message)
{
$chrArray[0] = "،";
Function parseResponse
has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring. Open
private function parseResponse($response)
{
$response_headers = '';
$raw_response = $response;
if (!(strpos($response, "\r\n\r\n") === false)) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function postfields
has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring. Open
private function postfields($data)
{
if (is_array($data)) {
if (self::is_array_multidim($data)) {
$data = self::http_build_multi_query($data);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function mobilesMangment
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
private function mobilesMangment($serviceVars = [])
{
if (!isset($serviceVars['action'])) {
throw new \Exception(' Not a valid action , or must be create,update,delete,get ');
}
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function groupsMangment
has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring. Open
private function groupsMangment($serviceVars = [])
{
if (!isset($serviceVars['action'])) {
throw new \Exception(' Not a valid action , or must be creat,delete,get,getMobiles ');
}
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method get
has 49 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function get($url_mixed, $data = [])
{
if (is_array($url_mixed)) {
$curl_multi = curl_multi_init();
$this->multi_parent = true;
Function printStringResult
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
function printStringResult($apiResult, $arrayMsgs, $printType = 'Alpha')
{
global $undefinedResult;
switch ($printType)
{
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method printStringResult
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
function printStringResult($apiResult, $arrayMsgs, $printType = 'Alpha')
{
global $undefinedResult;
switch ($printType)
{
Method mobilesMangment
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
private function mobilesMangment($serviceVars = [])
{
if (!isset($serviceVars['action'])) {
throw new \Exception(' Not a valid action , or must be create,update,delete,get ');
}
Method groupsMangment
has 36 lines of code (exceeds 25 allowed). Consider refactoring. Open
private function groupsMangment($serviceVars = [])
{
if (!isset($serviceVars['action'])) {
throw new \Exception(' Not a valid action , or must be creat,delete,get,getMobiles ');
}
Method sendSMSWK
has 11 arguments (exceeds 4 allowed). Consider refactoring. Open
function sendSMSWK($userAccount, $passAccount, $numbers, $sender, $msg, $msgKey, $MsgID, $timeSend=0, $dateSend=0, $deleteKey=0, $viewResult=1)
Method sendSMSWK
has 11 arguments (exceeds 4 allowed). Consider refactoring. Open
function sendSMSWK($userAccount, $passAccount, $numbers, $sender, $msg, $msgKey, $MsgID, $timeSend=0, $dateSend=0, $deleteKey=0, $viewResult=1)
Method sendSMSWK
has 11 arguments (exceeds 4 allowed). Consider refactoring. Open
function sendSMSWK($userAccount, $passAccount, $numbers, $sender, $msg, $msgKey, $MsgID, $timeSend=0, $dateSend=0, $deleteKey=0, $viewResult=1)
Method sendSMSWK
has 11 arguments (exceeds 4 allowed). Consider refactoring. Open
function sendSMSWK($userAccount, $passAccount, $numbers, $sender, $msg, $msgKey, $MsgID, $timeSend=0, $dateSend=0, $deleteKey=0, $viewResult=1)
Method sendSMSWK
has 11 arguments (exceeds 4 allowed). Consider refactoring. Open
function sendSMSWK($userAccount, $passAccount, $numbers, $sender, $msg, $msgKey, $MsgID, $timeSend=0, $dateSend=0, $deleteKey=0, $viewResult=1)