Completed
Pull Request — develop (#27)
by Neil
11:07
created
app/Http/Controllers/DeviceController.php 1 patch
Unused Use Statements   -3 removed lines patch added patch discarded remove patch
@@ -3,11 +3,8 @@
 block discarded – undo
3 3
 namespace App\Http\Controllers;
4 4
 
5 5
 use Dingo\Api\Http;
6
-use Dingo\Api\Routing\Router;
7 6
 use Dingo\Api\Routing\Helpers;
8
-use App\Http\Requests;
9 7
 use Illuminate\Http\Request;
10
-use JWTAuth;
11 8
 
12 9
 class HomeController extends Controller
13 10
 {
Please login to merge, or discard this patch.
app/Http/Controllers/PortController.php 1 patch
Unused Use Statements   -3 removed lines patch added patch discarded remove patch
@@ -3,11 +3,8 @@
 block discarded – undo
3 3
 namespace App\Http\Controllers;
4 4
 
5 5
 use Dingo\Api\Http;
6
-use Dingo\Api\Routing\Router;
7 6
 use Dingo\Api\Routing\Helpers;
8
-use App\Http\Requests;
9 7
 use Illuminate\Http\Request;
10
-use JWTAuth;
11 8
 
12 9
 class HomeController extends Controller
13 10
 {
Please login to merge, or discard this patch.
app/Api/Controllers/APIController.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -39,8 +39,8 @@
 block discarded – undo
39 39
     }
40 40
 
41 41
     /**
42
-    * Get info about the install
43
-    */
42
+     * Get info about the install
43
+     */
44 44
     public function get_info() {
45 45
         $schema = DB::select('SELECT `version` FROM `dbSchema` LIMIT 1');
46 46
         $versions['git'] = `git rev-parse --short HEAD`;
Please login to merge, or discard this patch.
Unused Use Statements   -4 removed lines patch added patch discarded remove patch
@@ -3,10 +3,6 @@
 block discarded – undo
3 3
 namespace App\Api\Controllers;
4 4
 
5 5
 use DB;
6
-use App\User;
7
-use App\Device;
8
-use App\Port;
9
-use Illuminate\Http\Request;
10 6
 
11 7
 class ApiController extends Controller
12 8
 {
Please login to merge, or discard this patch.
app/Api/Controllers/DeviceController.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,6 @@
 block discarded – undo
4 4
 
5 5
 use App\User;
6 6
 use App\Device;
7
-use App\Port;
8 7
 use Illuminate\Http\Request;
9 8
 
10 9
 class DeviceController extends Controller
Please login to merge, or discard this patch.
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
         if ($request->query('displayFormat') == 'human') {
32 32
         }
33 33
 
34
-       return $devices;
34
+        return $devices;
35 35
     }
36 36
 
37 37
     /**
Please login to merge, or discard this patch.
app/Port.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -45,13 +45,13 @@
 block discarded – undo
45 45
     // TODO: move to a common file
46 46
     // base = 1024 for bits, 1000 for mibibits
47 47
     function formatBps($bits, $precision = 2, $base=1000) {
48
-       $units = array('bps', 'Kbps', 'Mbps', 'Gbps', 'Tbps');
48
+        $units = array('bps', 'Kbps', 'Mbps', 'Gbps', 'Tbps');
49 49
 
50
-       $bits = max($bits, 0);
51
-       $pow = floor(($bits ? log($bits) : 0) / log($base));
52
-       $pow = min($pow, count($units) - 1);
50
+        $bits = max($bits, 0);
51
+        $pow = floor(($bits ? log($bits) : 0) / log($base));
52
+        $pow = min($pow, count($units) - 1);
53 53
 
54
-       $bits /= pow($base, $pow);
54
+        $bits /= pow($base, $pow);
55 55
 
56 56
         return round($bits, $precision) . ' ' . $units[$pow];
57 57
     }
Please login to merge, or discard this patch.