From 438d3484838a12f3f805949c9d4a08b21aabc619 Mon Sep 17 00:00:00 2001 From: Florian Baumann Date: Tue, 11 Jan 2022 08:55:34 +0100 Subject: [PATCH] Cut utm_source from url in cardview --- src/serra/helpers.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/serra/helpers.go b/src/serra/helpers.go index 1d59f32..181edd2 100644 --- a/src/serra/helpers.go +++ b/src/serra/helpers.go @@ -3,6 +3,7 @@ package serra import ( "errors" "fmt" + "strings" "time" "go.mongodb.org/mongo-driver/bson" @@ -69,7 +70,7 @@ func show_card_details(card *Card) error { fmt.Printf("* %dx %s%s%s (%s/%s)\n", card.SerraCount, Purple, card.Name, Reset, card.Set, card.CollectorNumber) fmt.Printf(" Added: %s\n", stringToTime(card.SerraCreated)) fmt.Printf(" Rarity: %s\n", card.Rarity) - fmt.Printf(" Scryfall: %s\n", card.ScryfallURI) + fmt.Printf(" Scryfall: %s\n", strings.Replace(card.ScryfallURI, "?utm_source=api", "", 1)) fmt.Printf(" Current Value: %s%.2f EUR%s\n", Yellow, card.Prices.Eur, Reset) fmt.Printf(" History:\n") for _, e := range card.SerraPrices {