Skip to content

Commit ab3b90a

Browse files
author
Fabiano Roberto
committed
feat(handler): return file content by key
1 parent 77005d7 commit ab3b90a

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

Handler/MediaHandler.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -537,6 +537,19 @@ public function getFullUrl(string $fullKey)
537537
return $toReturn;
538538
}
539539

540+
/**
541+
* @param string $fullKey
542+
*
543+
* @return bool|false|string
544+
*/
545+
public function getFileContent(string $fullKey)
546+
{
547+
/* @var AwsS3Adapter|LocalAdapter $adapter */
548+
$adapter = $this->filesystem->getAdapter();
549+
550+
return $adapter->read($fullKey);
551+
}
552+
540553
/**
541554
* @param string $key
542555
*

0 commit comments

Comments
 (0)