diff --git a/frappe/utils/setup_docs.py b/frappe/utils/setup_docs.py index 85f3d9a19d..9001ed835e 100644 --- a/frappe/utils/setup_docs.py +++ b/frappe/utils/setup_docs.py @@ -116,8 +116,10 @@ class setup_docs(object): # make /user user_path = os.path.join(self.docs_path, "user") - if not os.path.exists(user_path): - os.makedirs(user_path) + if os.path.exists(user_path): + shutil.rmtree(user_path, ignore_errors=True) + + os.makedirs(user_path) # make /assets/img img_path = os.path.join(self.docs_path, "assets", "img")