diff --git a/Classes/Service/PixxioClient.php b/Classes/Service/PixxioClient.php index c0af0d6..5731e05 100644 --- a/Classes/Service/PixxioClient.php +++ b/Classes/Service/PixxioClient.php @@ -193,7 +193,7 @@ public function updateFile(string $id, array $metadata): ResponseInterface public function search(string $queryExpression, array $formatTypes, array $fileTypes, int $offset = 0, int $limit = 50, $orderings = []): ResponseInterface { $options = new \stdClass(); - $options->pagination = $limit . '-' . intval($offset / $limit + 1); + $options->pagination = $limit . '-' . (int)($offset / $limit + 1); $options->imageOptions = $this->imageOptions; $options->fields = $this->fields; $options->formatType = $formatTypes; diff --git a/README.md b/README.md index d30bc3c..ea92dcf 100644 --- a/README.md +++ b/README.md @@ -166,8 +166,9 @@ Tagging used assets of asset source "flownative-pixxio" via Pixxio API: (tagged) nikhita-s-615116-unsplash 368 (1) ``` -As already mentioned, it is recommended to run this command through a cron-job, ideally in combination with -the `media:removeunused` command. +It is recommended to run this command through a cron-job, ideally in combination with the `media:removeunused` +command. It's important to run the `removeunused`-command *after* the tagging command, because otherwise removed +images will not be untagged in the Pixxio media library. Note: At this point, the auto-tagging feature is not really optimized for performance. The command merely iterates over all assets which were imported from Pixxio and checks if tags need to be updated.