Skip to content

Commit

Permalink
Check for valid category
Browse files Browse the repository at this point in the history
Signed-off-by: snipe <[email protected]>
  • Loading branch information
snipe committed Oct 31, 2022
1 parent 7cb4740 commit a930661
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion resources/views/account/view-assets.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,11 @@ class="table table-striped snipe-table"
<img src="{{ Storage::disk('public')->url(app('models_upload_path').e($asset->model->image)) }}" style="max-height: 30px; width: auto" class="img-responsive">
@endif
</td>
<td>{{ $asset->model->category->name }}</td>
<td>
@if (($asset->model) && ($asset->model->category))
{{ $asset->model->category->name }}
@endif
</td>
<td>{{ $asset->asset_tag }}</td>
<td>{{ $asset->name }}</td>
<td>
Expand Down

0 comments on commit a930661

Please sign in to comment.