Passed
Pull Request — master (#885)
by Maxence
02:20
created
lib/Provider/DeckProvider.php 3 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@
 block discarded – undo
77 77
 	 * DeckProvider constructor.
78 78
 	 *
79 79
 	 * @param IL10N $l10n
80
-	 * @param IUrlGenerator $urlGenerator
80
+	 * @param IURLGenerator $urlGenerator
81 81
 	 * @param FullTextSearchService $fullTextSearchService
82 82
 	 */
83 83
 	public function __construct(
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -42,7 +42,6 @@
 block discarded – undo
42 42
 use OCP\FullTextSearch\Model\ISearchResult;
43 43
 use OCP\FullTextSearch\Model\SearchTemplate;
44 44
 use OCP\IL10N;
45
-use OCP\IURLGenerator;
46 45
 
47 46
 
48 47
 /**
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -240,7 +240,7 @@
 block discarded – undo
240 240
 		foreach ($searchResult->getDocuments() as $document) {
241 241
 			try {
242 242
 				$board =
243
-					$this->fullTextSearchService->getBoardFromCardId((int)$document->getId());
243
+					$this->fullTextSearchService->getBoardFromCardId((int) $document->getId());
244 244
 				$path = '#!/board/' . $board->getId() . '//card/' . $document->getId();
245 245
 				$document->setLink($this->urlGenerator->linkToRoute('deck.page.index') . $path);
246 246
 			} catch (DoesNotExistException $e) {
Please login to merge, or discard this patch.
lib/Service/FullTextSearchService.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
 		$userId = $e->getArgument('userId');
95 95
 
96 96
 		$this->fullTextSearchManager->createIndex(
97
-			DeckProvider::DECK_PROVIDER_ID, (string)$cardId, $userId, IIndex::INDEX_FULL
97
+			DeckProvider::DECK_PROVIDER_ID, (string) $cardId, $userId, IIndex::INDEX_FULL
98 98
 		);
99 99
 	}
100 100
 
@@ -106,7 +106,7 @@  discard block
 block discarded – undo
106 106
 		$cardId = $e->getArgument('id');
107 107
 
108 108
 		$this->fullTextSearchManager->updateIndexStatus(
109
-			DeckProvider::DECK_PROVIDER_ID, (string)$cardId, IIndex::INDEX_CONTENT
109
+			DeckProvider::DECK_PROVIDER_ID, (string) $cardId, IIndex::INDEX_CONTENT
110 110
 		);
111 111
 	}
112 112
 
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
 		$cardId = $e->getArgument('id');
119 119
 
120 120
 		$this->fullTextSearchManager->updateIndexStatus(
121
-			DeckProvider::DECK_PROVIDER_ID, (string)$cardId, IIndex::INDEX_REMOVE
121
+			DeckProvider::DECK_PROVIDER_ID, (string) $cardId, IIndex::INDEX_REMOVE
122 122
 		);
123 123
 	}
124 124
 
@@ -149,7 +149,7 @@  discard block
 block discarded – undo
149 149
 	 * @return IndexDocument
150 150
 	 */
151 151
 	public function generateIndexDocumentFromCard(Card $card): IndexDocument {
152
-		$document = new IndexDocument(DeckProvider::DECK_PROVIDER_ID, (string)$card->getId());
152
+		$document = new IndexDocument(DeckProvider::DECK_PROVIDER_ID, (string) $card->getId());
153 153
 
154 154
 		return $document;
155 155
 	}
@@ -164,7 +164,7 @@  discard block
 block discarded – undo
164 164
 	public function fillIndexDocument(IndexDocument $document) {
165 165
 		try {
166 166
 			/** @var Card $card */
167
-			$card = $this->cardMapper->find((int)$document->getId());
167
+			$card = $this->cardMapper->find((int) $document->getId());
168 168
 		} catch (DoesNotExistException $e) {
169 169
 		} catch (MultipleObjectsReturnedException $e) {
170 170
 		}
@@ -234,7 +234,7 @@  discard block
 block discarded – undo
234 234
 	 * @throws MultipleObjectsReturnedException
235 235
 	 */
236 236
 	public function getBoardFromCardId(int $cardId): Board {
237
-		$boardId = (int)$this->cardMapper->findBoardId($cardId);
237
+		$boardId = (int) $this->cardMapper->findBoardId($cardId);
238 238
 		/** @var Board $board */
239 239
 		$board = $this->boardMapper->find($boardId);
240 240
 
Please login to merge, or discard this patch.