Skip to content

Commit df3df02

Browse files
committed
Keep indexing README.html for now
1 parent 9161967 commit df3df02

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

readthedocs/projects/tasks/search.py

+2-6
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
from readthedocs.builds.models import Build, Version
77
from readthedocs.projects.models import HTMLFile, Project
88
from readthedocs.projects.signals import files_changed
9-
from readthedocs.proxito.views.utils import allow_readme_html_as_index
109
from readthedocs.search.documents import PageDocument
1110
from readthedocs.search.utils import index_objects, remove_indexed_files
1211
from readthedocs.storage import build_media_storage
@@ -204,11 +203,8 @@ def _create_imported_files_and_search_index(
204203

205204
# Create the imported file only if it's a top-level 404 file,
206205
# or if it's an index file. We don't need to keep track of all files.
207-
if allow_readme_html_as_index():
208-
tryfiles = ["index.html", "README.html"]
209-
else:
210-
tryfiles = ["index.html"]
211-
206+
# TODO: delete README.html from this list after deprecation.
207+
tryfiles = ["index.html", "README.html"]
212208
if relpath == "404.html" or filename in tryfiles:
213209
html_files_to_save.append(html_file)
214210

0 commit comments

Comments
 (0)