settings = $settings; $this->uploadDir = $filesystemFactory->disk('flarum-assets'); } /** * {@inheritdoc} */ protected function delete(ServerRequestInterface $request) { RequestUtil::getActor($request)->assertAdmin(); $path = $this->settings->get('logo_path'); $this->settings->set('logo_path', null); if ($this->uploadDir->exists($path)) { $this->uploadDir->delete($path); } return new EmptyResponse(204); } }