Disallow uploads if app is locked

Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
snipe
2022-11-03 13:52:23 -07:00
parent 7cb1ca8754
commit 3c7d63c060
3 changed files with 19 additions and 1 deletions
@@ -27,6 +27,11 @@ class ComponentsFilesController extends Controller
*/
public function store(AssetFileRequest $request, $componentId = null)
{
if (config('app.lock_passwords')) {
return redirect()->route('components.show', ['component'=>$componentId])->with('error', trans('general.feature_disabled'));
}
$component = Component::find($componentId);
if (isset($component->id)) {