From 34c0940e6cd6d222f2234d81433fef38ca3a3738 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?John=20Ankarstr=C3=B6m?= Date: Wed, 6 Apr 2022 23:06:56 +0200 Subject: Persist "View Watched" setting. --- pl/cfg.pl | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'pl') diff --git a/pl/cfg.pl b/pl/cfg.pl index f24e44e..90b1e94 100644 --- a/pl/cfg.pl +++ b/pl/cfg.pl @@ -22,12 +22,19 @@ get_root(V) :- set_glob(V) :- set_key('EpisodeRoot', V). get_glob(V) :- - ( get_key('EpisodeRoot', V) + ( get_key('EpisodeRoot', V), ! ; V = '*/*.*' ). set_url(V) :- set_key('UrlPrefix', V). get_url(V) :- - ( get_key('UrlPrefix', V) + ( get_key('UrlPrefix', V), ! ; V = 'https://gogoanime.fi/detective-conan-episode-' ). + +set_view_watched(V) :- set_key('ViewWatched', V). +get_view_watched(V) :- + ( get_key('ViewWatched', V), + integer(V), ! + ; V = 1 + ). -- cgit v1.2.3