From 942c583c899adbb6fc066d98a15ab9417de921b4 Mon Sep 17 00:00:00 2001 From: Linus Dierheimer Date: Wed, 23 Mar 2022 21:41:52 +0100 Subject: [PATCH] Media: Don't show website urls --- CMakeLists.txt | 2 +- src/modules/song.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 29848df2c..26fd7f301 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,7 +7,7 @@ project(fastfetch #e.g. +1 #This allows to track builds between versions, without GitHub creating a new release -set(PROJECT_VERSION_EXTRA "+2") +set(PROJECT_VERSION_EXTRA "+3") include(GNUInstallDirs) diff --git a/src/modules/song.c b/src/modules/song.c index 2d34b7ebb..ed38f57ac 100644 --- a/src/modules/song.c +++ b/src/modules/song.c @@ -87,7 +87,8 @@ void ffPrintSong(FFinstance* instance) fputs(" - ", stdout); } - if(media->album.length > 0) + //Some sites (e.g. reddit) expose their url as album. We don't want to show that + if(media->album.length > 0 && !ffStrbufStartsWithIgnCaseS(&media->album, "http")) { ffStrbufWriteTo(&media->album, stdout); fputs(" - ", stdout);