Skip to content

Commit

Permalink
fix: fixup previous commit
Browse files Browse the repository at this point in the history
  • Loading branch information
OmarIthawi committed Nov 19, 2023
1 parent cb72dc1 commit 6a22743
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions drag_and_drop_v2/drag_and_drop_v2.py
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,8 @@ def _learner_raw_score(self):
correct_count, total_count = self._get_item_stats()
return correct_count / float(total_count)

def get_deprecated_i18n_js_url(self):
@staticmethod
def get_deprecated_i18n_js_url():
"""
Returns the deprecated JavaScript translation file for the currently selected language, if any found by
`pkg_resources`
Expand Down Expand Up @@ -371,7 +372,7 @@ def student_view(self, context):

if static_i18n_js_url := self.get_javascript_i18n_catalog_url():
fragment.add_javascript_url(static_i18n_js_url)
elif deprecated_i18n_js_url := self.get_deprecated_i18n_js_url():
elif deprecated_i18n_js_url := DragAndDropBlock.get_deprecated_i18n_js_url():
fragment.add_javascript_url(self.runtime.local_resource_url(self, deprecated_i18n_js_url))

self.include_theme_files(fragment)
Expand Down

0 comments on commit 6a22743

Please sign in to comment.