mirror of
https://github.com/snipe/snipe-it.git
synced 2025-02-02 08:21:09 -08:00
Update AssetModelsController.php
This commit is contained in:
parent
918e7c8dae
commit
1699c09758
|
@ -269,7 +269,7 @@ class AssetModelsController extends Controller
|
|||
*/
|
||||
public function getClone($modelId = null)
|
||||
{
|
||||
$this->authorize('view', AssetModel::class);
|
||||
$this->authorize('create', AssetModel::class);
|
||||
// Check if the model exists
|
||||
if (is_null($model_to_clone = AssetModel::find($modelId))) {
|
||||
return redirect()->route('models.index')->with('error', trans('admin/models/message.does_not_exist'));
|
||||
|
|
Loading…
Reference in a new issue