Commits

Steve Losh committed 413a89f

Don't match directories when filtering on file size.

  • Participants
  • Parent commits 8de084a

Comments (0)

Files changed (1)

 
     return p
 
-
 def build_type_set(types):
     if not types:
         return TYPES_ALL
 
     return result
 
-
 def parse_size(size):
     size = size.replace(' ', '') if size else size
 
     options.larger_than = parse_size(options.larger_than)
     options.smaller_than = parse_size(options.smaller_than)
 
+    if options.larger_than or options.smaller_than:
+        # Directory sizes are not supported.
+        options.type = options.type - TYPES_DIR
+
     # Go!
     search(query)