Skip to content

Commit

Permalink
Fix styling
Browse files Browse the repository at this point in the history
  • Loading branch information
daurensky authored and github-actions[bot] committed Apr 3, 2024
1 parent 2b8a1c6 commit 5458a9f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src/Models/Review.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@

namespace AdminKit\Reviews\Models;

use Spatie\MediaLibrary\HasMedia;
use Spatie\MediaLibrary\InteractsWithMedia;
use AdminKit\Core\Abstracts\Models\AbstractModel;
use AdminKit\Reviews\Database\Factories\ReviewFactory;
use Illuminate\Database\Eloquent\Casts\Attribute;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Spatie\MediaLibrary\HasMedia;
use Spatie\MediaLibrary\InteractsWithMedia;
use Spatie\Translatable\HasTranslations;
use AdminKit\Reviews\Database\Factories\ReviewFactory;

/**
* @property-read string $text
Expand Down
3 changes: 2 additions & 1 deletion src/UI/API/Controllers/ReviewController.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
namespace AdminKit\Reviews\UI\API\Controllers;

use AdminKit\Reviews\Models\Review;
use Spatie\LaravelData\DataCollection;
use AdminKit\Reviews\UI\API\Data\ReviewData;
use Spatie\LaravelData\DataCollection;

class ReviewController extends Controller
{
Expand All @@ -15,6 +15,7 @@ public function index(): DataCollection
$reviews = Review::query()
->latest()
->get();

return ReviewData::collection($reviews);
}
}
5 changes: 2 additions & 3 deletions src/UI/API/Data/ReviewData.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

namespace AdminKit\Reviews\UI\API\Data;

use Spatie\LaravelData\Data;
use AdminKit\Reviews\Models\Review;
use Spatie\LaravelData\Data;

class ReviewData extends Data
{
Expand All @@ -12,8 +12,7 @@ public function __construct(
public string $author,
public string $bio,
public string $photo,
)
{
) {
}

public static function fromModel(Review $review): ReviewData
Expand Down

0 comments on commit 5458a9f

Please sign in to comment.