修正
This commit is contained in:
@@ -14,15 +14,9 @@ export default function Setting(props) {
|
||||
const [mapSwitch, setMapSwitch] = useState(undefined);
|
||||
const [stationMenu, setStationMenu] = useState(undefined);
|
||||
useEffect(() => {
|
||||
AsyncStorage.getItem("iconSwitch").then((d) => {
|
||||
setIconSetting(d);
|
||||
});
|
||||
AsyncStorage.getItem("mapSwitch").then((d) => {
|
||||
setMapSwitch(d);
|
||||
});
|
||||
AsyncStorage.getItem("stationSwitch").then((d) => {
|
||||
setStationMenu(d);
|
||||
});
|
||||
AsyncStorage.getItem("iconSwitch").then(setIconSetting);
|
||||
AsyncStorage.getItem("mapSwitch").then(setMapSwitch);
|
||||
AsyncStorage.getItem("stationSwitch").then(setStationMenu);
|
||||
}, []);
|
||||
return (
|
||||
<View style={{ height: "100%", backgroundColor: "#0099CC" }}>
|
||||
|
Reference in New Issue
Block a user