mpv2oboeru

mpv helpers to create flashcards from movies and TV shows
git clone anongit@rnpnr.xyz:mpv2oboeru.git
Log | Files | Refs | Feed | README | LICENSE

Commit: e302e12849fe28afe531e2ae07cb19e7cc1aacdd
Parent: 02296f4df1c8d90680e451c0909343a3142003a8
Author: Ren Tatsumoto
Date:   Fri, 30 Oct 2020 20:30:11 +0300

simplify if

Diffstat:
Msubs2srs.lua | 8+-------
1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/subs2srs.lua b/subs2srs.lua @@ -604,13 +604,7 @@ ankiconnect.ensure_target_deck_exists = function() end ankiconnect.add_note = function(note_fields, gui) - local action - if gui then - action = 'guiAddCards' - else - action = 'addNote' - end - + local action = gui and 'guiAddCards' or 'addNote' local tags = is_empty(config.note_tag) and {} or { config.note_tag } local args = { action = action,