Skip to content

Commit

Permalink
fix(unlock-app): making sure the location is added only if it is defined
Browse files Browse the repository at this point in the history
  • Loading branch information
julien51 committed May 22, 2024
1 parent add92b8 commit 5d8c24b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion unlock-app/src/components/content/event/Form.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,12 @@ export const GoogleMapsAutoComplete = ({
},
apiKey: config.googleMapsApiKey,
onPlaceSelected: (place, inputRef) => {
if (place.formatted_address) {
// @ts-expect-error Property 'value' does not exist on type 'RefObject<HTMLInputElement>'.ts(2339)
return onChange(`${inputRef.value}, ${place.formatted_address}`)
}
// @ts-expect-error Property 'value' does not exist on type 'RefObject<HTMLInputElement>'.ts(2339)
return onChange(`${inputRef.value}, ${place.formatted_address}`)
return onChange(inputRef.value)
},
})

Expand Down

0 comments on commit 5d8c24b

Please sign in to comment.