summaryrefslogtreecommitdiffstats
path: root/lib/public
diff options
context:
space:
mode:
authorMarcel Klehr <mklehr@gmx.net>2023-11-06 14:53:20 +0100
committerMarcel Klehr <mklehr@gmx.net>2023-11-06 14:53:20 +0100
commitfecf6425cff5d3d67fd874780189d053e70a0074 (patch)
tree82f8155eec236d601a0b5d4d3678c652eacc6726 /lib/public
parentb01e0c31fbf833035bc9e10d7344fcd67071906b (diff)
downloadnextcloud-server-fecf6425cff5d3d67fd874780189d053e70a0074.tar.gz
nextcloud-server-fecf6425cff5d3d67fd874780189d053e70a0074.zip
fix: psalm issues and coding style
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Diffstat (limited to 'lib/public')
-rw-r--r--lib/public/TextProcessing/Exception/TaskFailureException.php5
-rw-r--r--lib/public/TextProcessing/Task.php21
2 files changed, 19 insertions, 7 deletions
diff --git a/lib/public/TextProcessing/Exception/TaskFailureException.php b/lib/public/TextProcessing/Exception/TaskFailureException.php
index 5f7b308757b..300864711e7 100644
--- a/lib/public/TextProcessing/Exception/TaskFailureException.php
+++ b/lib/public/TextProcessing/Exception/TaskFailureException.php
@@ -2,6 +2,9 @@
namespace OCP\TextProcessing\Exception;
+/**
+ * Exception thrown when a task failed
+ * @since 28.0.0
+ */
class TaskFailureException extends \RuntimeException {
-
}
diff --git a/lib/public/TextProcessing/Task.php b/lib/public/TextProcessing/Task.php
index 16850348358..f6b3a1a6a42 100644
--- a/lib/public/TextProcessing/Task.php
+++ b/lib/public/TextProcessing/Task.php
@@ -224,11 +224,20 @@ final class Task implements \JsonSerializable {
];
}
-final public function setCompletionExpectedAt(\DateTime $completionExpectedAt): void {
- $this->completionExpectedAt = $completionExpectedAt;
-}
+ /**
+ * @param null|\DateTime $completionExpectedAt
+ * @return void
+ * @since 28.0.0
+ */
+ final public function setCompletionExpectedAt(?\DateTime $completionExpectedAt): void {
+ $this->completionExpectedAt = $completionExpectedAt;
+ }
-final public function getCompletionExpectedAt(): ?\DateTime {
- return $this->completionExpectedAt;
-}
+ /**
+ * @return \DateTime|null
+ * @since 28.0.0
+ */
+ final public function getCompletionExpectedAt(): ?\DateTime {
+ return $this->completionExpectedAt;
+ }
}