summaryrefslogtreecommitdiffstats
path: root/apps/files_reminders/lib/Controller/ApiController.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/files_reminders/lib/Controller/ApiController.php')
-rw-r--r--apps/files_reminders/lib/Controller/ApiController.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/files_reminders/lib/Controller/ApiController.php b/apps/files_reminders/lib/Controller/ApiController.php
index 10a6654d671..de69997f616 100644
--- a/apps/files_reminders/lib/Controller/ApiController.php
+++ b/apps/files_reminders/lib/Controller/ApiController.php
@@ -83,7 +83,7 @@ class ApiController extends OCSController {
*
* @param string $dueDate ISO 8601 formatted date time string
*/
- public function create(int $fileId, string $dueDate): JSONResponse {
+ public function set(int $fileId, string $dueDate): JSONResponse {
try {
$dueDate = (new DateTime($dueDate))->setTimezone(new DateTimeZone('UTC'));
} catch (Exception $e) {
@@ -97,7 +97,7 @@ class ApiController extends OCSController {
}
try {
- $this->reminderService->create($user, $fileId, $dueDate);
+ $this->reminderService->createOrUpdate($user, $fileId, $dueDate);
return new JSONResponse([], Http::STATUS_OK);
} catch (Throwable $th) {
$this->logger->error($th->getMessage(), ['exception' => $th]);