Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Hide map when no information is present #2266

Merged
merged 1 commit into from
Aug 9, 2019
Merged

fix: Hide map when no information is present #2266

merged 1 commit into from
Aug 9, 2019

Conversation

anhanh11001
Copy link
Contributor

Detail:

  • When event doesn't contain any location details (latitude, longitude), imageMap is hide

Fixes: #2256

Detail:
- When event doesn't contain any location details (latitude, longitude), imageMap is hide

Fixes: #2256
@auto-label auto-label bot added the fix label Aug 9, 2019
@@ -459,8 +459,7 @@ class EventDetailsFragment : Fragment() {
// load location to map
val mapClickListener = View.OnClickListener { startMap(event) }

val locationNameIsEmpty = event.locationName.isNullOrEmpty()
if (!locationNameIsEmpty) {
if (!event.locationName.isNullOrEmpty() && event.longitude != null && event.latitude != null) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What if the only location name is there, the map should display, right?

@iamareebjamal iamareebjamal changed the title fix: Map display nothing fix: Hide map when no information is present Aug 9, 2019
@iamareebjamal iamareebjamal merged commit 3efe6b2 into fossasia:development Aug 9, 2019
@anhanh11001 anhanh11001 deleted the 2256_display_map branch August 9, 2019 19:18
liveHarshit pushed a commit to liveHarshit/open-event-attendee-android that referenced this pull request Aug 11, 2019
Detail:
- When event doesn't contain any location details (latitude, longitude), imageMap is hide

Fixes: fossasia#2256
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Map in EventDetailsFragment showing nothing
3 participants