Remove unused code

- Remove commented code
- Remove unused/immediately overwritten variables
- Remove extraneous parameters
- Remove unreachable code
- Remove duplicate array keys
This commit is contained in:
Hypolite Petovan 2019-01-07 12:09:10 -05:00
commit 4a95ca280d
42 changed files with 43 additions and 218 deletions

View file

@ -92,8 +92,6 @@ class Network
*/
public static function curl($url, $binary = false, &$redirects = 0, $opts = [])
{
$ret = ['return_code' => 0, 'success' => false, 'header' => '', 'info' => '', 'body' => ''];
$stamp1 = microtime(true);
$a = \get_app();
@ -322,7 +320,6 @@ class Network
$s = @curl_exec($ch);
$base = $s;
$curl_info = curl_getinfo($ch);
$curlResponse = new CurlResult($url, $s, $curl_info, curl_errno($ch), curl_error($ch));

View file

@ -113,8 +113,6 @@ class ParseUrl
*/
public static function getSiteinfo($url, $no_guessing = false, $do_oembed = true, $count = 1)
{
$a = \get_app();
$siteinfo = [];
// Check if the URL does contain a scheme

View file

@ -287,9 +287,6 @@ class XML
//Initializations
$xml_array = [];
$parents = [];
$opened_tags = [];
$arr = [];
$current = &$xml_array; // Reference