Skip to content

Commit dc5f3d7

Browse files
committed
fix: Correct typing
Signed-off-by: Louis Chmn <[email protected]>
1 parent 18be1cc commit dc5f3d7

File tree

5 files changed

+4
-6
lines changed

5 files changed

+4
-6
lines changed

lib/Controller/CardApiController.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,11 +72,11 @@ public function create($title, $type = 'plain', $order = 999, $description = '',
7272
$card = $this->cardService->create($title, $this->request->getParam('stackId'), $type, $order, $this->userId, $description, $duedate);
7373

7474
foreach ($labels as $labelId) {
75-
$this->cardService->assignLabel($card->id, $labelId);
75+
$this->cardService->assignLabel($card->getId(), $labelId);
7676
}
7777

7878
foreach ($users as $user) {
79-
$this->assignmentService->assignUser($card->id, $user['id'], $user['type']);
79+
$this->assignmentService->assignUser($card->getId(), $user['id'], $user['type']);
8080
}
8181

8282
return new DataResponse($card, HTTP::STATUS_OK);

lib/Db/Assignment.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
use JsonSerializable;
1111

1212
class Assignment extends RelationalEntity implements JsonSerializable {
13-
public $id;
1413
protected $participant;
1514
protected $cardId;
1615
protected $type;

lib/Db/Session.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
use OCP\AppFramework\Db\Entity;
1313

1414
class Session extends Entity implements \JsonSerializable {
15-
public $id;
1615
protected $userId;
1716
protected $token;
1817
protected $lastContact;

lib/Service/FilesAppService.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@ public function markAsDeleted(Attachment $attachment) {
312312
*/
313313
private function getShareForAttachment(Attachment $attachment): IShare {
314314
try {
315-
$share = $this->shareProvider->getShareById($attachment->getId());
315+
$share = $this->shareProvider->getShareById((string)$attachment->getId());
316316
} catch (ShareNotFound $e) {
317317
throw new NoPermissionException('No permission to access the attachment from the card');
318318
}

lib/Sharing/DeckShareProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ public function restore(IShare $share, string $recipient): IShare {
419419

420420
$qb->executeStatement();
421421

422-
return $this->getShareById((int)$share->getId(), $recipient);
422+
return $this->getShareById((string)$share->getId(), $recipient);
423423
}
424424

425425
/**

0 commit comments

Comments
 (0)