@@ -19,7 +19,7 @@ |
||
| 19 | 19 | */ |
| 20 | 20 | public function register() |
| 21 | 21 | { |
| 22 | - $this->getContainer()->singleton('Database', function () { |
|
| 22 | + $this->getContainer()->singleton('Database', function() { |
|
| 23 | 23 | $config = $this->getContainer()->get('config')['database']; |
| 24 | 24 | |
| 25 | 25 | $pdo = new ExtendedPdo( |
@@ -19,7 +19,7 @@ |
||
| 19 | 19 | */ |
| 20 | 20 | public function register() |
| 21 | 21 | { |
| 22 | - $this->getContainer()->singleton('Database\Data', function () { |
|
| 22 | + $this->getContainer()->singleton('Database\Data', function() { |
|
| 23 | 23 | $config = $this->getContainer()->get('config')['database_data']; |
| 24 | 24 | |
| 25 | 25 | $pdo = new ExtendedPdo( |
@@ -15,9 +15,9 @@ discard block |
||
| 15 | 15 | /** |
| 16 | 16 | * Construct |
| 17 | 17 | * |
| 18 | - * @param Ps2alerts\Api\Repository\AlertRepository $repository |
|
| 19 | - * @param Ps2alerts\Api\Transformer\AlertTransformer $transformer |
|
| 20 | - * @param League\Fractal\Manager $fractal |
|
| 18 | + * @param AlertRepository $repository |
|
| 19 | + * @param AlertTransformer $transformer |
|
| 20 | + * @param Manager $fractal |
|
| 21 | 21 | */ |
| 22 | 22 | public function __construct( |
| 23 | 23 | AlertRepository $repository, |
@@ -32,11 +32,11 @@ discard block |
||
| 32 | 32 | /** |
| 33 | 33 | * Returns a single alert's information |
| 34 | 34 | * |
| 35 | - * @param Symfony\Component\HttpFoundation\Request $request |
|
| 36 | - * @param Symfony\Component\HttpFoundation\Response $response |
|
| 35 | + * @param Request $request |
|
| 36 | + * @param Response $response |
|
| 37 | 37 | * @param array $args |
| 38 | 38 | * |
| 39 | - * @return \League\Fractal\TransformerAbstract |
|
| 39 | + * @return Response |
|
| 40 | 40 | */ |
| 41 | 41 | public function getSingle(Request $request, Response $response, array $args) |
| 42 | 42 | { |
@@ -52,10 +52,10 @@ discard block |
||
| 52 | 52 | /** |
| 53 | 53 | * Returns all currently running alerts |
| 54 | 54 | * |
| 55 | - * @param Symfony\Component\HttpFoundation\Request $request |
|
| 56 | - * @param Symfony\Component\HttpFoundation\Response $response |
|
| 55 | + * @param Request $request |
|
| 56 | + * @param Response $response |
|
| 57 | 57 | * |
| 58 | - * @return \League\Fractal\TransformerAbstract |
|
| 58 | + * @return Response |
|
| 59 | 59 | */ |
| 60 | 60 | public function getActives(Request $request, Response $response) |
| 61 | 61 | { |
@@ -71,10 +71,10 @@ discard block |
||
| 71 | 71 | /** |
| 72 | 72 | * Returns all alerts in historial order |
| 73 | 73 | * |
| 74 | - * @param Symfony\Component\HttpFoundation\Request $request |
|
| 75 | - * @param Symfony\Component\HttpFoundation\Response $response |
|
| 74 | + * @param Request $request |
|
| 75 | + * @param Response $response |
|
| 76 | 76 | * |
| 77 | - * @return \League\Fractal\TransformerAbstract |
|
| 77 | + * @return Response |
|
| 78 | 78 | */ |
| 79 | 79 | public function getHistoryByDate(Request $request, Response $response) |
| 80 | 80 | { |
@@ -5,7 +5,6 @@ |
||
| 5 | 5 | use League\Fractal\Manager; |
| 6 | 6 | use Ps2alerts\Api\Controller\Endpoint\AbstractEndpointController; |
| 7 | 7 | use Ps2alerts\Api\Repository\AlertRepository; |
| 8 | -use Ps2alerts\Api\Transformer\AlertTotalTransformer; |
|
| 9 | 8 | use Ps2alerts\Api\Transformer\AlertTransformer; |
| 10 | 9 | use Symfony\Component\HttpFoundation\Request; |
| 11 | 10 | use Symfony\Component\HttpFoundation\Response; |
@@ -93,11 +93,11 @@ |
||
| 93 | 93 | $limit = (int) $request->get('limit'); |
| 94 | 94 | |
| 95 | 95 | // Set defaults if not supplied |
| 96 | - if ($offset === null || ! is_numeric($offset)) { |
|
| 96 | + if ($offset === null || !is_numeric($offset)) { |
|
| 97 | 97 | $offset = 0; |
| 98 | 98 | } |
| 99 | 99 | |
| 100 | - if ($limit === null || ! is_numeric($limit)) { |
|
| 100 | + if ($limit === null || !is_numeric($limit)) { |
|
| 101 | 101 | $limit = 25; |
| 102 | 102 | } |
| 103 | 103 | |
@@ -24,8 +24,8 @@ |
||
| 24 | 24 | 'host' => $_ENV['REDIS_HOST'], |
| 25 | 25 | 'db' => $_ENV['REDIS_DB'] |
| 26 | 26 | ], |
| 27 | - 'servers' => [1,10,13,17,25,1000,2000], |
|
| 28 | - 'zones' => [2,4,6,8], |
|
| 29 | - 'factions' => ['vs','nc','tr','draw'], |
|
| 30 | - 'brackets' => ['MOR','AFT','PRI'] |
|
| 27 | + 'servers' => [1, 10, 13, 17, 25, 1000, 2000], |
|
| 28 | + 'zones' => [2, 4, 6, 8], |
|
| 29 | + 'factions' => ['vs', 'nc', 'tr', 'draw'], |
|
| 30 | + 'brackets' => ['MOR', 'AFT', 'PRI'] |
|
| 31 | 31 | ]; |