Passed
Push — master ( 68934c...d986dd )
by Julius
05:31 queued 03:21
created
appinfo/routes.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -112,6 +112,6 @@
 block discarded – undo
112 112
 		['name' => 'attachment_api#delete', 'url' => '/api/v1.0/boards/{boardId}/stacks/{stackId}/cards/{cardId}/attachments/{attachmentId}', 'verb' => 'DELETE'],
113 113
 		['name' => 'attachment_api#restore', 'url' => '/api/v1.0/boards/{boardId}/stacks/{stackId}/cards/{cardId}/attachments/{attachmentId}/restore', 'verb' => 'PUT'],
114 114
 
115
-		['name' => 'board_api#preflighted_cors', 'url' => '/api/v1.0/{path}','verb' => 'OPTIONS', 'requirements' => ['path' => '.+']],
115
+		['name' => 'board_api#preflighted_cors', 'url' => '/api/v1.0/{path}', 'verb' => 'OPTIONS', 'requirements' => ['path' => '.+']],
116 116
 	]
117 117
 ];
Please login to merge, or discard this patch.
lib/Service/DefaultBoardService.php 1 patch
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
 	private $config;
41 41
 	private $l10n;
42 42
 
43
-    public function __construct(
43
+	public function __construct(
44 44
 			IL10N $l10n,
45 45
 			BoardMapper $boardMapper,
46 46
 			BoardService $boardService,
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
 		$this->config = $config;
56 56
 		$this->boardMapper = $boardMapper;
57 57
 		$this->l10n = $l10n;
58
-    }
58
+	}
59 59
 
60 60
 	/**
61 61
 	 * @param $userId
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
 		}
74 74
 
75 75
 		return false;
76
-    }
76
+	}
77 77
 
78 78
 	/**
79 79
 	 * @param $title
@@ -100,9 +100,9 @@  discard block
 block discarded – undo
100 100
 			throw new BadRequestException('color must be provided');
101 101
 		}
102 102
 
103
-        $defaultBoard = $this->boardService->create($title, $userId, $color);
104
-        $defaultStacks = [];
105
-        $defaultCards = [];
103
+		$defaultBoard = $this->boardService->create($title, $userId, $color);
104
+		$defaultStacks = [];
105
+		$defaultCards = [];
106 106
 
107 107
 		$boardId = $defaultBoard->getId();		
108 108
 
@@ -115,5 +115,5 @@  discard block
 block discarded – undo
115 115
 		$defaultCards[] = $this->cardService->create($this->l10n->t('Example Task 1'), $defaultStacks[2]->getId(), 'text', 0, $userId);
116 116
 
117 117
 		return $defaultBoard;
118
-    }
118
+	}
119 119
 }
120 120
\ No newline at end of file
Please login to merge, or discard this patch.
lib/Controller/BoardApiController.php 1 patch
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -25,10 +25,8 @@
 block discarded – undo
25 25
 namespace OCA\Deck\Controller;
26 26
 
27 27
 use OCP\AppFramework\ApiController;
28
-use OCP\AppFramework\Http;
29 28
 use OCP\AppFramework\Http\DataResponse;
30 29
 use OCP\IRequest;
31
-
32 30
 use OCA\Deck\Service\BoardService;
33 31
 
34 32
 /**
Please login to merge, or discard this patch.
lib/Db/BoardMapper.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -173,6 +173,9 @@
 block discarded – undo
173 173
 		return ($board->getOwner() === $userId);
174 174
 	}
175 175
 
176
+	/**
177
+	 * @param string $id
178
+	 */
176 179
 	public function findBoardId($id) {
177 180
 		return $id;
178 181
 	}
Please login to merge, or discard this patch.
appinfo/app.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
  *
22 22
  */
23 23
 
24
-if ((@include_once __DIR__ . '/../vendor/autoload.php')===false) {
24
+if ((@include_once __DIR__ . '/../vendor/autoload.php') === false) {
25 25
 	throw new Exception('Cannot include autoload. Did you run install dependencies using composer?');
26 26
 }
27 27
 
Please login to merge, or discard this patch.
lib/Db/DeckMapper.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -45,6 +45,9 @@
 block discarded – undo
45 45
 		return $this->findEntity($sql, [$id]);
46 46
 	}
47 47
 
48
+	/**
49
+	 * @param string $sql
50
+	 */
48 51
 	protected function execute($sql, array $params = [], $limit = null, $offset = null) {
49 52
 		return parent::execute($sql, $params, $limit, $offset);
50 53
 	}
Please login to merge, or discard this patch.
lib/Db/LabelMapper.php 1 patch
Doc Comments   +6 added lines patch added patch discarded remove patch
@@ -66,6 +66,9 @@  discard block
 block discarded – undo
66 66
 		return $result;
67 67
 	}
68 68
 
69
+	/**
70
+	 * @param integer $labelId
71
+	 */
69 72
 	public function deleteLabelAssignments($labelId) {
70 73
 		$sql = 'DELETE FROM `*PREFIX*deck_assigned_labels` WHERE label_id = ?';
71 74
 		$stmt = $this->db->prepare($sql);
@@ -73,6 +76,9 @@  discard block
 block discarded – undo
73 76
 		$stmt->execute();
74 77
 	}
75 78
 
79
+	/**
80
+	 * @param integer $cardId
81
+	 */
76 82
 	public function deleteLabelAssignmentsForCard($cardId) {
77 83
 		$sql = 'DELETE FROM `*PREFIX*deck_assigned_labels` WHERE card_id = ?';
78 84
 		$stmt = $this->db->prepare($sql);
Please login to merge, or discard this patch.
lib/Middleware/SharingMiddleware.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,6 @@
 block discarded – undo
24 24
 namespace OCA\Deck\Middleware;
25 25
 
26 26
 use OCA\Deck\StatusException;
27
-use OCA\Deck\BadRequestException;
28 27
 use OCP\AppFramework\Db\DoesNotExistException;
29 28
 use OCP\AppFramework\Middleware;
30 29
 use OCP\AppFramework\Http\JSONResponse;
Please login to merge, or discard this patch.
lib/Service/StackService.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,6 @@
 block discarded – undo
34 34
 use OCA\Deck\Db\StackMapper;
35 35
 use OCA\Deck\StatusException;
36 36
 use OCA\Deck\BadRequestException;
37
-use OCP\Comments\ICommentsManager;
38 37
 
39 38
 
40 39
 class StackService {
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
 	private function enrichStackWithCards($stack, $since = -1) {
78 78
 		$cards = $this->cardMapper->findAll($stack->getId(), null, null, $since);
79 79
 
80
-		if(\count($cards) === 0) {
80
+		if (\count($cards) === 0) {
81 81
 			return;
82 82
 		}
83 83
 
@@ -216,7 +216,7 @@  discard block
 block discarded – undo
216 216
 	 */
217 217
 	public function delete($id) {
218 218
 
219
-		if ( is_numeric($id) === false ) {
219
+		if (is_numeric($id) === false) {
220 220
 			throw new BadRequestException('stack id must be a number');
221 221
 		}
222 222
 
Please login to merge, or discard this patch.