From 5ad76ed2e6e67b421c27ff153e2ae348152eaa40 Mon Sep 17 00:00:00 2001 From: Vidhu Kant Sharma Date: Thu, 30 Jun 2022 00:22:46 +0530 Subject: added confirmation message and color coding when setting anime status --- cmd/status.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'cmd') diff --git a/cmd/status.go b/cmd/status.go index feb5c10..dcf177c 100644 --- a/cmd/status.go +++ b/cmd/status.go @@ -68,8 +68,8 @@ func setAnimeStatus(statusInput, searchInput string) { if statusInput == "" { ui.AnimeStatusMenu(anime) } else { - mal.SetAnimeStatus(anime.Id, statusInput) - fmt.Printf("Successfully set \"%s\" to \"%s\"\n", anime.Title, statusInput) + resp := mal.SetAnimeStatus(anime.Id, statusInput) + fmt.Println(ui.CreateStatusUpdateConfirmationMessage(anime.Title, resp.Status)) } } @@ -83,8 +83,8 @@ func setMangaStatus(statusInput, searchInput string) { if statusInput == "" { ui.MangaStatusMenu(manga) } else { - mal.SetAnimeStatus(manga.Id, statusInput) - fmt.Printf("Successfully set \"%s\" to \"%s\"\n", manga.Title, statusInput) + resp := mal.SetAnimeStatus(manga.Id, statusInput) + fmt.Println(ui.CreateStatusUpdateConfirmationMessage(manga.Title, resp.Status)) } } -- cgit v1.2.3