diff --git a/platform_plugin_turnitin/utils.py b/platform_plugin_turnitin/utils.py index 7235a4a..2e2b1b5 100644 --- a/platform_plugin_turnitin/utils.py +++ b/platform_plugin_turnitin/utils.py @@ -1,6 +1,6 @@ """Utility functions for the Turnitin platform plugin.""" -from datetime import datetime +from datetime import datetime, timezone from opaque_keys.edx.keys import UsageKey @@ -18,7 +18,7 @@ def get_current_datetime() -> str: Returns: str: The current datetime in ISO 8601 format. """ - return datetime.utcnow().strftime("%Y-%m-%dT%H:%M:%SZ") + return datetime.now(timezone.utc).strftime("%Y-%m-%dT%H:%M:%SZ") def enabled_in_course(block_id: str) -> bool: