mirror of
https://github.com/espocrm/espocrm.git
synced 2026-06-28 06:56:05 +00:00
type fixes
This commit is contained in:
@@ -30,6 +30,7 @@
|
||||
namespace Espo\Controllers;
|
||||
|
||||
use Espo\Core\Exceptions\Forbidden;
|
||||
use Espo\Core\Exceptions\BadRequest;
|
||||
|
||||
use Espo\Core\{
|
||||
Upgrades\ExtensionManager,
|
||||
@@ -51,6 +52,10 @@ class Extension extends RecordBase
|
||||
{
|
||||
$body = $request->getBodyContents();
|
||||
|
||||
if ($body === null) {
|
||||
throw new BadRequest();
|
||||
}
|
||||
|
||||
$manager = new ExtensionManager($this->getContainer());
|
||||
|
||||
$id = $manager->upload($body);
|
||||
|
||||
Reference in New Issue
Block a user