diff options
author | Max Kellermann <max@duempel.org> | 2011-05-09 21:37:43 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2011-05-09 21:37:43 +0200 |
commit | 4b4aa64261154bcb1e521b98629c0640d6b259f7 (patch) | |
tree | e901de6264797d243bc8d3352ab2f033ff45977f /src/directory.h | |
parent | 26735390fffaa467bf90041a5c380802602affb6 (diff) | |
download | mpd-4b4aa64261154bcb1e521b98629c0640d6b259f7.tar.gz mpd-4b4aa64261154bcb1e521b98629c0640d6b259f7.tar.xz mpd-4b4aa64261154bcb1e521b98629c0640d6b259f7.zip |
directory: allow directories with just playlists
Keep those when scanning for empty directories. The check in
playlist_vector_is_empty() was missing.
Diffstat (limited to 'src/directory.h')
-rw-r--r-- | src/directory.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/directory.h b/src/directory.h index 69e2b3638..151cf5423 100644 --- a/src/directory.h +++ b/src/directory.h @@ -62,7 +62,8 @@ directory_free(struct directory *directory); static inline bool directory_is_empty(const struct directory *directory) { - return directory->children.nr == 0 && directory->songs.nr == 0; + return directory->children.nr == 0 && directory->songs.nr == 0 && + playlist_vector_is_empty(&directory->playlists); } static inline const char * |