Skip to content

Commit

Permalink
Remove inconsistent infix from internal helper methods
Browse files Browse the repository at this point in the history
  • Loading branch information
caendesilva committed Jul 26, 2024
1 parent 2f28d87 commit 879b767
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/framework/src/Support/Filesystem/MediaFile.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class MediaFile extends ProjectFile
/** @return array<string, \Hyde\Support\Filesystem\MediaFile> The array keys are the filenames relative to the _media/ directory */
public static function all(): array
{
return static::discoverMediaAssetFiles();
return static::discoverMediaFiles();
}

/** @return array<string> Array of filenames relative to the _media/ directory */
Expand Down Expand Up @@ -123,16 +123,16 @@ public function getMimeType(): string
return 'text/plain';
}

protected static function discoverMediaAssetFiles(): array
protected static function discoverMediaFiles(): array
{
return collect(static::getMediaAssetFiles())->mapWithKeys(function (string $path): array {
return collect(static::getMediaFiles())->mapWithKeys(function (string $path): array {
$file = static::make($path);

return [$file->getIdentifier() => $file];
})->all();
}

protected static function getMediaAssetFiles(): array
protected static function getMediaFiles(): array
{
return glob(Hyde::path(static::getMediaGlobPattern()), GLOB_BRACE) ?: [];
}
Expand Down

0 comments on commit 879b767

Please sign in to comment.