|
@@ -395,7 +395,7 @@ class Filesystem extends AbstractData
|
|
|
public function getAllPastes()
|
|
public function getAllPastes()
|
|
|
{
|
|
{
|
|
|
$pastes = array();
|
|
$pastes = array();
|
|
|
- foreach ($this->_getPasteIterator() as $file) {
|
|
|
|
|
|
|
+ foreach (new \GlobIterator($this->_path . self::PASTE_FILE_PATTERN) as $file) {
|
|
|
if ($file->isFile()) {
|
|
if ($file->isFile()) {
|
|
|
$pastes[] = $file->getBasename('.php');
|
|
$pastes[] = $file->getBasename('.php');
|
|
|
}
|
|
}
|
|
@@ -439,20 +439,6 @@ class Filesystem extends AbstractData
|
|
|
'.discussion' . DIRECTORY_SEPARATOR;
|
|
'.discussion' . DIRECTORY_SEPARATOR;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- /**
|
|
|
|
|
- * Get an iterator matching paste files.
|
|
|
|
|
- *
|
|
|
|
|
- * Note that creating the iterator issues the glob() call, so we can't pre-
|
|
|
|
|
- * generate this object before files that should get matched exist.
|
|
|
|
|
- *
|
|
|
|
|
- * @access private
|
|
|
|
|
- * @return \GlobIterator
|
|
|
|
|
- */
|
|
|
|
|
- private function _getPasteIterator()
|
|
|
|
|
- {
|
|
|
|
|
- return new \GlobIterator($this->_path . self::PASTE_FILE_PATTERN);
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
/**
|
|
/**
|
|
|
* store the data
|
|
* store the data
|
|
|
*
|
|
*
|