mirror of
https://github.com/mue/mue.git
synced 2026-07-27 18:51:05 +02:00
refactor: cleanup
This commit is contained in:
@@ -33,7 +33,7 @@ export default class TimeSettings extends PureComponent {
|
||||
|
||||
getAuto() {
|
||||
navigator.geolocation.getCurrentPosition(async (position) => {
|
||||
const data = await (await fetch(`${window.constants.PROXY_URL}/weather/autolocation?lat=${position.coords.latitude}&lon=${position.coords.longitude}`)).json();
|
||||
const data = await (await fetch(`${variables.constants.PROXY_URL}/weather/autolocation?lat=${position.coords.latitude}&lon=${position.coords.longitude}`)).json();
|
||||
this.setState({
|
||||
location: data[0].name
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user