From 130e1b43fbc62eec1d3a5add8e15b1ef8863dcff Mon Sep 17 00:00:00 2001 From: Nicolas Werner Date: Tue, 30 Aug 2022 22:05:33 +0200 Subject: [PATCH] Fix empty widgets still being shown --- src/timeline/TimelineModel.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/timeline/TimelineModel.cpp b/src/timeline/TimelineModel.cpp index 4820513f..b7122db1 100644 --- a/src/timeline/TimelineModel.cpp +++ b/src/timeline/TimelineModel.cpp @@ -2795,6 +2795,10 @@ TimelineModel::widgetLinks() const list.reserve(evs.size()); for (const auto &p : evs) { auto url = QString::fromStdString(p.content.url); + + if (url.isEmpty()) + continue; + for (const auto &[k, v] : p.content.data) url.replace("$" + QString::fromStdString(k), QUrl::toPercentEncoding(QString::fromStdString(v)));