From 9de189cdbfe492816f5e95567ef546da9895d6c9 Mon Sep 17 00:00:00 2001 From: David Ormsbee Date: Mon, 5 Feb 2024 23:22:44 -0500 Subject: [PATCH] fix: forgot to set the default for file creation back to False after debugging --- openedx_learning/core/contents/admin.py | 2 ++ openedx_learning/core/contents/api.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/openedx_learning/core/contents/admin.py b/openedx_learning/core/contents/admin.py index bb48e766..036d171b 100644 --- a/openedx_learning/core/contents/admin.py +++ b/openedx_learning/core/contents/admin.py @@ -21,6 +21,7 @@ class ContentAdmin(ReadOnlyModelAdmin): "media_type", "size", "created", + "has_file", ] fields = [ "learning_package", @@ -30,6 +31,7 @@ class ContentAdmin(ReadOnlyModelAdmin): "created", "file_link", "text_preview", + "has_file", ] list_filter = ("media_type", "learning_package") search_fields = ("hash_digest",) diff --git a/openedx_learning/core/contents/api.py b/openedx_learning/core/contents/api.py index 11db02de..020c9e57 100644 --- a/openedx_learning/core/contents/api.py +++ b/openedx_learning/core/contents/api.py @@ -73,7 +73,7 @@ def get_or_create_text_content( media_type_id: int, text: str, created: datetime, - create_file: bool=True, + create_file: bool=False, ) -> Content: """ Get or create a Content entry with text data stored in the database.