From 184e50a825b2b852fdf9121c0816cf11a91841db Mon Sep 17 00:00:00 2001
From: Andrew <mcdeweykp@gmail.com>
Date: Mon, 9 May 2022 13:34:45 -0400
Subject: [PATCH] Fix bug where excluded dir not persistant

---
 app/classes/web/ajax_handler.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/app/classes/web/ajax_handler.py b/app/classes/web/ajax_handler.py
index ee788e78..5c479e50 100644
--- a/app/classes/web/ajax_handler.py
+++ b/app/classes/web/ajax_handler.py
@@ -200,7 +200,7 @@ class AjaxHandler(BaseHandler):
                     if os.path.isdir(rel):
                         output += f"""<li class="tree-item" data-path="{dpath}">
                             \n<div id="{dpath}" data-path="{dpath}" data-name="{filename}" class="tree-caret tree-ctx-item tree-folder">
-                            <input type="checkbox" name="root_path" value="{dpath}">
+                            <input type="checkbox" name="root_path" value="{dpath}" checked>
                             <span id="{dpath}span" class="files-tree-title" data-path="{dpath}" data-name="{filename}" onclick="getDirView(event)">
                             <i class="far fa-folder"></i>
                             <i class="far fa-folder-open"></i>
@@ -212,7 +212,7 @@ class AjaxHandler(BaseHandler):
                         class="tree-item tree-nested d-block tree-ctx-item tree-file"
                         data-path="{dpath}"
                         data-name="{filename}"
-                        onclick=""><input type='checkbox' name='root_path' value='{dpath}'><span style="margin-right: 6px;">
+                        onclick=""><input type='checkbox' name='root_path' value='{dpath}' checked><span style="margin-right: 6px;">
                         <i class="far fa-file"></i></span></input>{filename}</li>"""
 
                 else: