Skip to content

Commit 1f9327c

Browse files
committed
fix(Share20): Use correct enum for share status
Signed-off-by: provokateurin <kate@provokateurin.de>
1 parent 640adf5 commit 1f9327c

2 files changed

Lines changed: 5 additions & 7 deletions

File tree

lib/private/Share20/Share.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ class Share implements IShare {
4848
private $permissions;
4949
/** @var IAttributes */
5050
private $attributes;
51-
/** @var int */
51+
/** @var self::STATUS_* */
5252
private $status;
5353
/** @var string */
5454
private $note = '';
@@ -358,7 +358,7 @@ public function setStatus(int $status): IShare {
358358
* @inheritdoc
359359
*/
360360
#[\Override]
361-
public function getStatus(): int {
361+
public function getStatus(): ?int {
362362
return $this->status;
363363
}
364364

lib/public/Share/IShare.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -320,22 +320,20 @@ public function getAttributes(): ?IAttributes;
320320

321321
/**
322322
* Set the accepted status
323-
* See self::STATUS_*
324323
*
325-
* @param int $status
324+
* @param self::STATUS_* $status
326325
* @return IShare The modified object
327326
* @since 18.0.0
328327
*/
329328
public function setStatus(int $status): IShare;
330329

331330
/**
332331
* Get the accepted status
333-
* See self::STATUS_*
334332
*
335-
* @return int
333+
* @return ?self::STATUS_*
336334
* @since 18.0.0
337335
*/
338-
public function getStatus(): int;
336+
public function getStatus(): ?int;
339337

340338
/**
341339
* Attach a note to a share

0 commit comments

Comments
 (0)