File tree Expand file tree Collapse file tree 1 file changed +2
-7
lines changed
Shared/Samples/Find address with reverse geocode Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -28,13 +28,8 @@ struct FindAddressWithReverseGeocodeView: View {
2828 /// The text shown in the callout.
2929 @State private var calloutText : String ?
3030
31- /// A Boolean value indicating whether the error alert is showing.
32- @State private var errorAlertIsShowing = false
33-
3431 /// The error shown in the error alert.
35- @State private var error : Error ? {
36- didSet { errorAlertIsShowing = error != nil }
37- }
32+ @State private var error : Error ?
3833
3934 var body : some View {
4035 MapView ( map: model. map, graphicsOverlays: [ model. graphicsOverlay] )
@@ -63,7 +58,7 @@ struct FindAddressWithReverseGeocodeView: View {
6358 . padding ( 8 )
6459 . background ( . thinMaterial, ignoresSafeAreaEdges: . horizontal)
6560 }
66- . alert ( isPresented : $errorAlertIsShowing , presentingError: error)
61+ . errorAlert ( presentingError: $ error)
6762 }
6863
6964 /// Reverse geocodes a given point and updates the marker with the result.
You can’t perform that action at this time.
0 commit comments