mirror of
https://github.com/nextcloud/server.git
synced 2026-05-28 04:32:30 -04:00
Allow using geolocation in the dashboard
Else the weather geolocation is kind of useless. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
parent
1f4c029977
commit
f6578b74f4
1 changed files with 8 additions and 1 deletions
|
|
@ -111,7 +111,14 @@ class DashboardController extends Controller {
|
|||
$this->inititalStateService->provideInitialState('dashboard', 'version', $this->config->getUserValue($this->userId, 'dashboard', 'backgroundVersion', 0));
|
||||
$this->config->setUserValue($this->userId, 'dashboard', 'firstRun', '0');
|
||||
|
||||
return new TemplateResponse('dashboard', 'index');
|
||||
$response = new TemplateResponse('dashboard', 'index');
|
||||
|
||||
// For the weather widget we should allow the geolocation
|
||||
$featurePolicy = new Http\FeaturePolicy();
|
||||
$featurePolicy->addAllowedGeoLocationDomain('\'self\'');
|
||||
$response->setFeaturePolicy($featurePolicy);
|
||||
|
||||
return $response;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue