Skip to content

Commit 31ec467

Browse files
Remove bad code about removing pdf/epub artifacts.
It was a missed attempt at the issue that I reverted but seem to have missed some lines. We clear the artifacts with the project.tasks.clear_pdf/epub_artifacts fucntions now. Syncer.remove is no valid method.
1 parent f7a0538 commit 31ec467

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

readthedocs/projects/tasks.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -668,17 +668,10 @@ def move_files(version_pk, hostname, html=False, localmedia=False, search=False,
668668
from_path = version.project.artifact_path(version=version.slug, type='sphinx_pdf')
669669
to_path = version.project.get_production_media_path(type='pdf', version_slug=version.slug, include_file=False)
670670
Syncer.copy(from_path, to_path, host=hostname)
671-
elif not version.project.enable_pdf_build:
672-
to_path = version.project.get_production_media_path(type='pdf', version_slug=version.slug, include_file=False)
673-
Syncer.remove(to_path)
674-
675671
if epub:
676672
from_path = version.project.artifact_path(version=version.slug, type='sphinx_epub')
677673
to_path = version.project.get_production_media_path(type='epub', version_slug=version.slug, include_file=False)
678674
Syncer.copy(from_path, to_path, host=hostname)
679-
elif not version.project.enable_epub_build:
680-
to_path = version.project.get_production_media_path(type='epub', version_slug=version.slug, include_file=False)
681-
Syncer.remove(to_path)
682675

683676
if 'mkdocs' in version.project.documentation_type:
684677
if search:

0 commit comments

Comments
 (0)