mirror of
https://github.com/beetbox/beets.git
synced 2025-12-25 18:13:17 +01:00
simplify path type coercion in MatchQuery (#470)
This commit is contained in:
parent
69e6ef7633
commit
1066c79b56
1 changed files with 1 additions and 4 deletions
|
|
@ -1027,10 +1027,7 @@ class MatchQuery(FieldQuery):
|
|||
def col_clause(self):
|
||||
pattern = self.pattern
|
||||
if self.field == 'path':
|
||||
if isinstance(pattern, unicode):
|
||||
pattern = bytestring_path(pattern)
|
||||
if isinstance(pattern, str):
|
||||
pattern = buffer(pattern)
|
||||
pattern = buffer(bytestring_path(pattern))
|
||||
return self.field + " = ?", [pattern]
|
||||
|
||||
# We override the "raw" version here as a special case because we
|
||||
|
|
|
|||
Loading…
Reference in a new issue