aboutsummaryrefslogtreecommitdiffstats
path: root/apps/weather_status/src
diff options
context:
space:
mode:
authordependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>2021-07-15 12:46:14 +0000
committerMichaIng <micha@dietpi.com>2021-07-23 15:56:28 +0200
commit6e5191b7021b448a48d741233bd17ab3c222119f (patch)
tree26c353643f5d1dd764d512e1fd15e15168d54346 /apps/weather_status/src
parent229bfcbab56e2de473d2d34bb7d86b5665d4ab35 (diff)
downloadnextcloud-server-6e5191b7021b448a48d741233bd17ab3c222119f.tar.gz
nextcloud-server-6e5191b7021b448a48d741233bd17ab3c222119f.zip
Bump @nextcloud/router from 1.2.0 to 2.0.0
Bumps [@nextcloud/router](https://github.com/nextcloud/nextcloud-router) from 1.2.0 to 2.0.0. - [Release notes](https://github.com/nextcloud/nextcloud-router/releases) - [Changelog](https://github.com/nextcloud/nextcloud-router/blob/master/CHANGELOG.md) - [Commits](https://github.com/nextcloud/nextcloud-router/compare/v1.2.0...v2.0.0) Signed-off-by: dependabot[bot] <support@github.com> Signed-off-by: npmbuildbot-nextcloud[bot] <npmbuildbot-nextcloud[bot]@users.noreply.github.com>
Diffstat (limited to 'apps/weather_status/src')
-rw-r--r--apps/weather_status/src/services/weatherStatusService.js16
1 files changed, 8 insertions, 8 deletions
diff --git a/apps/weather_status/src/services/weatherStatusService.js b/apps/weather_status/src/services/weatherStatusService.js
index e6c5e6a2c35..7f4fc35316c 100644
--- a/apps/weather_status/src/services/weatherStatusService.js
+++ b/apps/weather_status/src/services/weatherStatusService.js
@@ -31,7 +31,7 @@ import { generateOcsUrl } from '@nextcloud/router'
* @returns {Promise<Object>}
*/
const setLocation = async(lat, lon) => {
- const url = generateOcsUrl('apps/weather_status/api/v1', 2) + 'location'
+ const url = generateOcsUrl('apps/weather_status/api/v1/location')
const response = await HttpClient.put(url, {
address: '',
lat,
@@ -47,7 +47,7 @@ const setLocation = async(lat, lon) => {
* @returns {Promise<Object>}
*/
const setAddress = async(address) => {
- const url = generateOcsUrl('apps/weather_status/api/v1', 2) + 'location'
+ const url = generateOcsUrl('apps/weather_status/api/v1/location')
const response = await HttpClient.put(url, {
address,
lat: null,
@@ -63,7 +63,7 @@ const setAddress = async(address) => {
* @returns {Promise<Object>}
*/
const setMode = async(mode) => {
- const url = generateOcsUrl('apps/weather_status/api/v1', 2) + 'mode'
+ const url = generateOcsUrl('apps/weather_status/api/v1/mode')
const response = await HttpClient.put(url, {
mode,
})
@@ -76,7 +76,7 @@ const setMode = async(mode) => {
* @returns {Promise<Object>}
*/
const usePersonalAddress = async() => {
- const url = generateOcsUrl('apps/weather_status/api/v1', 2) + 'use-personal'
+ const url = generateOcsUrl('apps/weather_status/api/v1/use-personal')
const response = await HttpClient.put(url)
return response.data.ocs.data
@@ -88,7 +88,7 @@ const usePersonalAddress = async() => {
* @returns {Promise<Object>}
*/
const getLocation = async() => {
- const url = generateOcsUrl('apps/weather_status/api/v1', 2) + 'location'
+ const url = generateOcsUrl('apps/weather_status/api/v1/location')
const response = await HttpClient.get(url)
return response.data.ocs.data
@@ -101,7 +101,7 @@ const getLocation = async() => {
* @returns {Promise<Object>}
*/
const fetchForecast = async() => {
- const url = generateOcsUrl('apps/weather_status/api/v1', 2) + 'forecast'
+ const url = generateOcsUrl('apps/weather_status/api/v1/forecast')
const response = await HttpClient.get(url)
return response.data.ocs.data
@@ -114,7 +114,7 @@ const fetchForecast = async() => {
* @returns {Promise<Object>}
*/
const getFavorites = async() => {
- const url = generateOcsUrl('apps/weather_status/api/v1', 2) + 'favorites'
+ const url = generateOcsUrl('apps/weather_status/api/v1/favorites')
const response = await HttpClient.get(url)
return response.data.ocs.data
@@ -126,7 +126,7 @@ const getFavorites = async() => {
* @returns {Promise<Object>}
*/
const saveFavorites = async(favorites) => {
- const url = generateOcsUrl('apps/weather_status/api/v1', 2) + 'favorites'
+ const url = generateOcsUrl('apps/weather_status/api/v1/favorites')
const response = await HttpClient.put(url, {
favorites,
})