diff --git a/src/Translator.php b/src/Translator.php index 8505380..2426b25 100644 --- a/src/Translator.php +++ b/src/Translator.php @@ -143,11 +143,12 @@ public function getGlossaryLanguages(): array /** * Translates specified text string or array of text strings into the target language. - * @param $texts string|string[] A single string or array of strings containing input texts to translate. + * @param string|string[] $texts A single string or array of strings containing input texts to translate. * @param string|null $sourceLang Language code of input text language, or null to use auto-detection. * @param string $targetLang Language code of language to translate into. * @param array $options Translation options to apply. See \DeepL\TranslateTextOptions. * @return TextResult|TextResult[] A TextResult or array of TextResult objects containing translated texts. + * @phpstan-return ($texts is array ? TextResult[] : TextResult) * @throws DeepLException * @see \DeepL\TranslateTextOptions */