Rename api/locations to api/readLocations and api/poiTyp to api/readPoiTyp
This commit is contained in:
@@ -332,7 +332,7 @@ const MapComponent = ({ locations, onLocationUpdate }) => {
|
||||
useEffect(() => {
|
||||
const fetchPoiTypData = async () => {
|
||||
try {
|
||||
const response = await fetch("/api/poiTyp");
|
||||
const response = await fetch("/api/readPoiTyp");
|
||||
const data = await response.json();
|
||||
setPoiTypData(data); // Daten im Recoil State speichern
|
||||
} catch (error) {
|
||||
|
||||
@@ -11,7 +11,7 @@ const ShowAddStationPopup = ({ map, latlng }) => {
|
||||
useEffect(() => {
|
||||
const fetchPoiTypData2 = async () => {
|
||||
try {
|
||||
const response = await fetch("/api/poiTyp");
|
||||
const response = await fetch("/api/readPoiTyp");
|
||||
const data = await response.json();
|
||||
setPoiTypData2(data);
|
||||
if (data && data.length > 0) {
|
||||
|
||||
Reference in New Issue
Block a user