Skip to content

Commit

Permalink
revert AssetController change
Browse files Browse the repository at this point in the history
  • Loading branch information
mabumusa1 committed Mar 30, 2023
1 parent 8053ea3 commit 78373e9
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion app/bundles/AssetBundle/Controller/AssetController.php
Original file line number Diff line number Diff line change
Expand Up @@ -315,6 +315,10 @@ public function newAction($entity = null)
$page = $session->get('mautic.asset.page', 1);
$action = $this->generateUrl('mautic_asset_action', ['objectAction' => 'new']);

// Get upload folder
$uploaderHelper = $this->container->get('oneup_uploader.templating.uploader_helper');
$uploadEndpoint = $uploaderHelper->endpoint('asset');

//create the form
$form = $model->createForm($entity, $this->get('form.factory'), $action);

Expand Down Expand Up @@ -386,7 +390,7 @@ public function newAction($entity = null)
'assetDownloadUrl' => $model->generateUrl($entity),
'integrations' => $integrations,
'startOnLocal' => $entity->isLocal(),
'uploadEndpoint' => $this->render('@MauticAssets/Asset/upload_endpoint.html.twig'),
'uploadEndpoint' => $uploadEndpoint,
'maxSize' => $maxSize,
'maxSizeError' => $maxSizeError,
'extensions' => $extensions,
Expand Down

0 comments on commit 78373e9

Please sign in to comment.