it would be useful to document the arguments. `path` is obvious, and maybe `directories_only` too (are you missing a default value to that arg?) but `details` is not immediately apparent. Does it need to be required?