mirror of
https://github.com/ksyasuda/aniwrapper.git
synced 2024-11-22 03:19:53 -08:00
allow episode 0
This commit is contained in:
parent
505e5125b9
commit
d061438e2e
2
ani-cli
2
ani-cli
@ -706,7 +706,7 @@ episode_selection() {
|
||||
read -r ep_choice_start ep_choice_end
|
||||
[[ -z "$ep_choice_end" ]] && ep_choice_end="$ep_choice_start"
|
||||
fi
|
||||
if (((ep_choice_start <= 0 || ep_choice_start > LAST_EP_NUMBER) || ep_choice_end < ep_choice_start || ep_choice_end > LAST_EP_NUMBER)); then
|
||||
if (((ep_choice_start < 0 || ep_choice_start > LAST_EP_NUMBER) || ep_choice_end < ep_choice_start || ep_choice_end > LAST_EP_NUMBER)); then
|
||||
die "Invalid episode/range entered: ep_start -> $ep_choice_start | ep_end -> $ep_choice_end"
|
||||
fi
|
||||
}
|
||||
|
@ -24,7 +24,6 @@ CREATE TABLE IF NOT EXISTS watch_history (
|
||||
episode_number integer NOT NULL,
|
||||
watch_date DATETIME NOT NULL,
|
||||
CHECK (LENGTH(anime_name) > 0),
|
||||
CHECK (episode_number > 0),
|
||||
UNIQUE (anime_name, episode_number, watch_date)
|
||||
);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user