From 56fe8eb6d7ef57a1c05a10349daaec8f80680559 Mon Sep 17 00:00:00 2001 From: ghost Date: Tue, 12 Sep 2023 17:16:50 +0300 Subject: [PATCH] fix data type returned by API --- src/crontab/export/feed.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/crontab/export/feed.php b/src/crontab/export/feed.php index b2bf0d0..06b2852 100644 --- a/src/crontab/export/feed.php +++ b/src/crontab/export/feed.php @@ -292,9 +292,9 @@ try 'title' => $magnet->title, 'preview' => $magnet->preview, 'description' => $magnet->description, - 'comments' => $magnet->comments, - 'sensitive' => $magnet->sensitive, - 'approved' => $magnet->approved, + 'comments' => (bool) $magnet->comments, + 'sensitive' => (bool) $magnet->sensitive, + 'approved' => (bool) $magnet->approved, 'timeAdded' => $magnet->timeAdded, 'timeUpdated' => $magnet->timeUpdated, 'dn' => $magnet->dn, @@ -393,7 +393,7 @@ try 'magnetStarId' => $star->magnetStarId, 'userId' => $star->userId, 'magnetId' => $star->magnetId, - 'value' => $star->value, + 'value' => (bool) $star->value, 'timeAdded' => $star->timeAdded, ]; }