[gnome-maps] placeBubble: Don't show invalid URLs
- From: Marcus Lundblad <mlundblad src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-maps] placeBubble: Don't show invalid URLs
- Date: Wed, 25 Nov 2020 21:31:12 +0000 (UTC)
commit 96560d3362a921bef8aa1a0c4f61bd0a4abdb4b7
Author: James Westman <james flyingpimonster net>
Date: Tue Nov 17 17:02:16 2020 -0600
placeBubble: Don't show invalid URLs
src/placeBubble.js | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
---
diff --git a/src/placeBubble.js b/src/placeBubble.js
index 96495366..d0d75d14 100644
--- a/src/placeBubble.js
+++ b/src/placeBubble.js
@@ -112,10 +112,12 @@ var PlaceBubble = GObject.registerClass({
let content = [];
if (place.website) {
- content.push({ label: _("Website"),
- icon: 'web-browser-symbolic',
- info: GLib.markup_escape_text(place.website, -1),
- linkUrl: place.website });
+ if (Utils.isValidWebsite(place.website)) {
+ content.push({ label: _("Website"),
+ icon: 'web-browser-symbolic',
+ info: GLib.markup_escape_text(place.website, -1),
+ linkUrl: place.website });
+ }
}
if (place.phone) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]