Merge pull request #13923 from snipe/bug/sc-24098

Quick revert for #13830
This commit is contained in:
snipe 2023-11-22 12:28:25 +00:00 committed by GitHub
commit eae98d3f35
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -534,8 +534,10 @@ class AssetsController extends Controller
* @since [v4.0]
* @return \Illuminate\Http\JsonResponse
*/
public function store(StoreAssetRequest $request)
public function store(ImageUploadRequest $request)
{
return Gate::allows('create', new Asset);
$asset = new Asset();
$asset->model()->associate(AssetModel::find((int) $request->get('model_id')));