Skip to content

Commit

Permalink
Fix geolocation getter and map being broken
Browse files Browse the repository at this point in the history
  • Loading branch information
hsjoberg committed Jul 1, 2024
1 parent 7811960 commit 4cc145c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/utils/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export const toast = (

export const getGeolocation = (): Promise<GeolocationResponse["coords"]> => {
return new Promise((resolve, reject) => {
Geolocation.getCurrentPosition(
Geolocation.default.getCurrentPosition(
(position) => {
resolve(position.coords);
},
Expand Down
4 changes: 2 additions & 2 deletions src/windows/TransactionDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import DialogAndroid from "react-native-dialogs";
import Clipboard from "@react-native-clipboard/clipboard";
import { Card, Text, CardItem, H1, View, Button, Icon } from "native-base";
import { fromUnixTime } from "date-fns";
import MapView, { PROVIDER_DEFAULT } from "react-native-maps";
import MapView, { PROVIDER_DEFAULT, Marker } from "react-native-maps";
import type Long from "long";

import Blurmodal from "../components/BlurModal";
Expand Down Expand Up @@ -406,7 +406,7 @@ export default function TransactionDetails({ route, navigation }: ITransactionDe
}}
customMapStyle={MapStyle[transactionGeolocationMapStyle]}
>
<MapView.Marker
<Marker
coordinate={{
longitude: transaction.locationLong!,
latitude: transaction.locationLat!,
Expand Down

0 comments on commit 4cc145c

Please sign in to comment.