A free open source IT asset/license management system
Ignore the soft deleted assets in the eloquent query (#6824)
Ivan Nieto8c65214b1f2b
diff --git a/app/Http/Controllers/Api/AssetsController.php b/app/Http/Controllers/Api/AssetsController.phpindex 6fa40f90fc..c6d83694a0 100644--- a/app/Http/Controllers/Api/AssetsController.php+++ b/app/Http/Controllers/Api/AssetsController.php@@ -279,7 +279,7 @@ class AssetsController extends Controller*/public function showByTag($tag){- if ($asset = Asset::with('assetstatus')->with('assignedTo')->withTrashed()->where('asset_tag',$tag)->first()) {+ if ($asset = Asset::with('assetstatus')->with('assignedTo')->where('asset_tag',$tag)->first()) {$this->authorize('view', $asset);return (new AssetsTransformer)->transformAsset($asset);}