Skip to content

Commit da19b0f

Browse files
committed
remove iterable check and missing return value
Signed-off-by: Kyle Sayers <kylesayrs@gmail.com>
1 parent b3e89a2 commit da19b0f

File tree

1 file changed

+4
-6
lines changed
  • src/compressed_tensors/quantization/lifecycle

1 file changed

+4
-6
lines changed

src/compressed_tensors/quantization/lifecycle/apply.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -331,12 +331,10 @@ def find_name_or_class_matches(
331331
3. matches on module names
332332
"""
333333
targets = sorted(targets, key=lambda x: ("re:" in x, x))
334-
if isinstance(targets, Iterable):
335-
matches = _find_matches(name, targets) + _find_matches(
336-
module.__class__.__name__, targets, check_contains
337-
)
338-
matches = [match for match in matches if match is not None]
339-
return matches
334+
matches = _find_matches(name, targets) + _find_matches(
335+
module.__class__.__name__, targets, check_contains
336+
)
337+
return [match for match in matches if match is not None]
340338

341339

342340
def _find_matches(

0 commit comments

Comments
 (0)