From cf944ff91ce7d741e99871209edcf8bc6f0ab75f Mon Sep 17 00:00:00 2001 From: Guy Sartorelli Date: Fri, 12 Jan 2024 10:39:17 +1300 Subject: [PATCH] ENH Add generic types --- src/Extension/FileTextExtractable.php | 3 ++- src/Extractor/FileTextExtractor.php | 1 - 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Extension/FileTextExtractable.php b/src/Extension/FileTextExtractable.php index fedccbc..6251843 100644 --- a/src/Extension/FileTextExtractable.php +++ b/src/Extension/FileTextExtractable.php @@ -14,6 +14,8 @@ * Adds an additional property which is the cached contents, which is populated on demand. * * @author mstephens + * + * @extends DataExtension */ class FileTextExtractable extends DataExtension { @@ -85,7 +87,6 @@ public function getFileContent() */ public function extractFileAsText($disableCache = false) { - /** @var File $file */ $file = $this->owner; if (!$disableCache) { $text = $this->getTextCache()->load($file); diff --git a/src/Extractor/FileTextExtractor.php b/src/Extractor/FileTextExtractor.php index d34cac9..8f2ee1b 100644 --- a/src/Extractor/FileTextExtractor.php +++ b/src/Extractor/FileTextExtractor.php @@ -87,7 +87,6 @@ public static function for_file($file) // Ensure we have a File instance to work with if (is_string($file)) { - /** @var File $fileObject */ $fileObject = File::create(); $fileObject->setFromLocalFile($file); $file = $fileObject;