Skip to content

Commit

Permalink
add slash to non-empty dirs in extra networks interface
Browse files Browse the repository at this point in the history
  • Loading branch information
AUTOMATIC1111 committed Feb 19, 2023
1 parent 66cfd1d commit fe46a08
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions modules/ui_extra_networks.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,10 @@ def create_html(self, tabname):
while subdir.startswith("/"):
subdir = subdir[1:]

is_empty = len(os.listdir(x)) == 0
if not is_empty and not subdir.endswith("/"):
subdir = subdir + "/"

subdirs[subdir] = 1

if subdirs:
Expand Down

0 comments on commit fe46a08

Please sign in to comment.