mirror of
https://github.com/beetbox/beets.git
synced 2025-12-31 04:52:49 +01:00
Fix breaking issues
This commit is contained in:
parent
4d648510cc
commit
5677f9beee
2 changed files with 3 additions and 2 deletions
|
|
@ -28,6 +28,7 @@ from re import Pattern
|
|||
from typing import TYPE_CHECKING, Any, Generic, TypeVar, Union
|
||||
|
||||
from beets import util
|
||||
from beets.util.units import raw_seconds_short
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from beets.dbcore.db import AnyModel, Model
|
||||
|
|
@ -892,7 +893,7 @@ class DurationQuery(NumericQuery):
|
|||
if not s:
|
||||
return None
|
||||
try:
|
||||
return util.raw_seconds_short(s)
|
||||
return raw_seconds_short(s)
|
||||
except ValueError:
|
||||
try:
|
||||
return float(s)
|
||||
|
|
|
|||
|
|
@ -1343,7 +1343,7 @@ def import_func(lib, opts, args: list[str]):
|
|||
|
||||
if opts.library:
|
||||
query = args
|
||||
paths = []
|
||||
byte_paths = []
|
||||
else:
|
||||
query = None
|
||||
paths = args
|
||||
|
|
|
|||
Loading…
Reference in a new issue