From bf96e9934016617881aaa2c665e1a6a5f2beccd3 Mon Sep 17 00:00:00 2001 From: Kevin Hill Date: Sat, 25 Apr 2015 00:19:52 -0700 Subject: [PATCH] removed some commented test code and ran php fixer --- src/Configs/DataTable.php | 27 +-------------------------- src/Lavacharts.php | 1 - src/Psr4Autoloader.php | 2 -- 3 files changed, 1 insertion(+), 29 deletions(-) diff --git a/src/Configs/DataTable.php b/src/Configs/DataTable.php index d81a20a9..bf10b2ba 100755 --- a/src/Configs/DataTable.php +++ b/src/Configs/DataTable.php @@ -525,15 +525,10 @@ public function hasFormats() */ public function toJson() { - $json = json_encode(array( + return json_encode(array( 'cols' => $this->cols, 'rows' => $this->rows, )); - - // Removes the "" from Date() so it is treated - // as a JS new Date() instead of a string. - //return preg_replace('/"(Date\([0-9,]+\))"/', 'new $1', $json); - return $json; } /** @@ -561,25 +556,6 @@ private function parseDate($date) } return $this->carbonToJsString($carbonDate); - //return $carbonDate->toIso8601String(); - } - - /** - * Outputs the Carbon object as a valid javascript Date string. - * - * @return string Javscript date declaration - */ - private function _carbonToJsString(Carbon $c) - { - // Javascript - //Wed Apr 15 2015 16:01:22 GMT-0700 (PDT) - //Sun Oct 19 2014 0:00:00 UTC+0000 - - // Carbon - //"Wed, 01 Oct 2014 00:00:00 +0000" - - return $c->format('D M j Y G:i:s TO'); - //return $c->toRfc2822String(); } /** @@ -599,5 +575,4 @@ private function carbonToJsString(Carbon $c) isset($c->second) ? $c->second : 'null' ); } - } diff --git a/src/Lavacharts.php b/src/Lavacharts.php index 1792b202..6a3f03e4 100755 --- a/src/Lavacharts.php +++ b/src/Lavacharts.php @@ -438,5 +438,4 @@ private function usingComposer() return false; } } - } diff --git a/src/Psr4Autoloader.php b/src/Psr4Autoloader.php index bb891746..d5313145 100755 --- a/src/Psr4Autoloader.php +++ b/src/Psr4Autoloader.php @@ -77,7 +77,6 @@ public function loadClass($class) // work backwards through the namespace names of the fully-qualified // class name to find a mapped file name while (false !== $pos = strrpos($prefix, '\\')) { - // retain the trailing namespace separator in the prefix $prefix = substr($class, 0, $pos + 1); @@ -116,7 +115,6 @@ protected function loadMappedFile($prefix, $relative_class) // look through base directories for this namespace prefix foreach ($this->prefixes[$prefix] as $base_dir) { - // replace the namespace prefix with the base directory, // replace namespace separators with directory separators // in the relative class name, append with .php