syntax fix, changelog

This commit is contained in:
Felix J. Ogris
2022-11-01 16:38:06 +01:00
parent 9a61e8fd48
commit bde5802a3a
7 changed files with 17 additions and 16 deletions

View File

@@ -78,7 +78,7 @@ class S3Storage extends AbstractData
*
* @access public
* @param array $options
* @return
* @return
*/
public function __construct(array $options)
{
@@ -453,15 +453,15 @@ class S3Storage extends AbstractData
public function getAllPastes()
{
$pastes = array();
$prefix = $this->_prefix;
$prefix = $this->_prefix;
if ($prefix != '') {
$prefix .= '/';
}
try {
foreach ($this->_listAllObjects($prefix) as $object) {
$candidate = substr($object["Key"], strlen($prefix));
if (strpos($candidate, "/") === false) {
$candidate = substr($object['Key'], strlen($prefix));
if (strpos($candidate, '/') === false) {
$pastes[] = $candidate;
}
}