force allowed files only when available

Signed-off-by: Victor Seiji Hariki <victorseijih@gmail.com>
pull/37/head
Victor Seiji Hariki 2023-01-17 19:35:46 -03:00
parent a9c74fe849
commit 8ac7bd9a13
1 changed files with 6 additions and 2 deletions

View File

@ -32,8 +32,12 @@ force_allow = get_files(f"{os.path.abspath(scripts.basedir())}/app")
def started(demo, app: FastAPI):
# Add to allowed files list
app.blocks.temp_file_sets.append(force_allow)
try:
# Add to allowed files list
app.blocks.temp_file_sets.append(force_allow)
except Exception:
print(f"[openOutpaint] Could not force allowed files. Skipping...")
pass
def add_tab():