Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
QuentinGab committed Dec 3, 2023
1 parent 6ffb121 commit 2387d5f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/Models/Media.php
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ public function getPath(string $conversion = null): ?string
public function generateBasePath(string $conversion = null): string
{
if ($conversion) {
return "{$this->uuid}/generated_conversions/" . str_replace('.', '/', $this->getConversionKey($conversion)) . '/';
return "{$this->uuid}/generated_conversions/".str_replace('.', '/', $this->getConversionKey($conversion)).'/';
}

return "{$this->uuid}/";
Expand Down Expand Up @@ -188,7 +188,7 @@ public function storeFileFromHttpFile(
$this->name = File::sanitizeFilename($name ?? File::name($file));

$this->file_name = "{$this->name}.{$this->extension}";
$this->path = Str::finish($basePath ?? $this->generateBasePath(), '/') . $this->file_name;
$this->path = Str::finish($basePath ?? $this->generateBasePath(), '/').$this->file_name;

$this->putFile($file, fileName: $this->file_name);

Expand Down Expand Up @@ -260,7 +260,7 @@ public function storeConversion(
name: $name,
extension: $extension,
file_name: $file_name,
path: ($basePath ?? $this->generateBasePath($conversion)) . $file_name,
path: ($basePath ?? $this->generateBasePath($conversion)).$file_name,
mime_type: $mime_type,
type: $type,
state: $state,
Expand Down
4 changes: 2 additions & 2 deletions tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ protected function setUp(): void
parent::setUp();

Factory::guessFactoryNamesUsing(
fn (string $modelName) => 'Finller\\Media\\Database\\Factories\\' . class_basename($modelName) . 'Factory'
fn (string $modelName) => 'Finller\\Media\\Database\\Factories\\'.class_basename($modelName).'Factory'
);
}

Expand All @@ -31,7 +31,7 @@ public function getEnvironmentSetUp($app)
{
config()->set('database.default', 'testing');

$migration = include __DIR__ . '/../database/migrations/create_media_table.php.stub';
$migration = include __DIR__.'/../database/migrations/create_media_table.php.stub';
$migration->up();

$app['db']->connection()->getSchemaBuilder()->create('tests', function (Blueprint $table) {
Expand Down

0 comments on commit 2387d5f

Please sign in to comment.