Cleanup previous PR

This commit is contained in:
Kovid Goyal 2024-12-17 08:45:14 +05:30
parent 58685d5260
commit bf78ffe7f2
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -160,7 +160,7 @@ def main(opts, args, dbctx):
if field == 'sort':
field = 'title_sort'
if field not in fields:
raise SystemExit(_('{} is not a known field'))
raise SystemExit(_('{} is not a known field').format(field))
if field == 'cover':
val = dbctx.path(os.path.abspath(os.path.expanduser(val)))
else:
@ -173,7 +173,7 @@ def main(opts, args, dbctx):
try:
val = float(val)
except Exception:
raise SystemExit('The value %r is not a valid series index' % val)
raise SystemExit(_('The value {!r} is not a valid series index').format(val))
fvals.append((field, val))
final_mi = dbctx.run('set_metadata', 'fields', book_id, fvals)