Commit c86f672b by David Baumgold

Fix spelling

parent 8e169e64
...@@ -41,7 +41,7 @@ class RecommenderXBlock(XBlock): ...@@ -41,7 +41,7 @@ class RecommenderXBlock(XBlock):
""" """
default_recommendations = List(help="List of default help resources", default_recommendations = List(help="List of default help resources",
default=[], scope=Scope.content) default=[], scope=Scope.content)
# A list of default recommenations, it is a JSON object across all users, # A list of default recommendations, it is a JSON object across all users,
# all runs of a course, for this xblock. # all runs of a course, for this xblock.
# Usage: default_recommendations[index] = { # Usage: default_recommendations[index] = {
# "id": (Integer) id of a resource, # "id": (Integer) id of a resource,
...@@ -56,7 +56,7 @@ class RecommenderXBlock(XBlock): ...@@ -56,7 +56,7 @@ class RecommenderXBlock(XBlock):
recommendations = List(help="List of help resources", default=[], recommendations = List(help="List of help resources", default=[],
scope=Scope.user_state_summary) scope=Scope.user_state_summary)
# A list of recommenations provided by students, it is a JSON object # A list of recommendations provided by students, it is a JSON object
# aggregated across many users of a single block. # aggregated across many users of a single block.
# Usage: the same as default_recommendations # Usage: the same as default_recommendations
...@@ -198,7 +198,7 @@ class RecommenderXBlock(XBlock): ...@@ -198,7 +198,7 @@ class RecommenderXBlock(XBlock):
result['toggle']: the boolean indicator for whether the resource was switched from downvoted to upvoted result['toggle']: the boolean indicator for whether the resource was switched from downvoted to upvoted
""" """
resource_id = data['id'] resource_id = data['id']
idx = self.recommenations.index(resource_id) idx = self.recommendations.index(resource_id)
result = {} result = {}
result['id'] = resource_id result['id'] = resource_id
if idx > len(self.recommendations): if idx > len(self.recommendations):
...@@ -247,7 +247,7 @@ class RecommenderXBlock(XBlock): ...@@ -247,7 +247,7 @@ class RecommenderXBlock(XBlock):
result['toggle']: the boolean indicator for whether the resource was switched from upvoted to downvoted result['toggle']: the boolean indicator for whether the resource was switched from upvoted to downvoted
""" """
resource_id = data['id'] resource_id = data['id']
idx = self.recommenations.index(resource_id) idx = self.recommendations.index(resource_id)
result = {} result = {}
result['id'] = resource_id result['id'] = resource_id
if idx > len(self.recommendations): if idx > len(self.recommendations):
...@@ -449,7 +449,7 @@ class RecommenderXBlock(XBlock): ...@@ -449,7 +449,7 @@ class RecommenderXBlock(XBlock):
resource_id = data['id'] resource_id = data['id']
result = {} result = {}
result['id'] = resource_id result['id'] = resource_id
idx = self.recommenations.index(resource_id) idx = self.recommendations.index(resource_id)
if idx > len(self.recommendations): if idx > len(self.recommendations):
result['error'] = 'bad id' result['error'] = 'bad id'
result['Success'] = False result['Success'] = False
...@@ -601,7 +601,7 @@ class RecommenderXBlock(XBlock): ...@@ -601,7 +601,7 @@ class RecommenderXBlock(XBlock):
resource_id = data['id'] resource_id = data['id']
result = {} result = {}
result['id'] = resource_id result['id'] = resource_id
idx = self.recommenations.index(resource_id) idx = self.recommendations.index(resource_id)
if idx > len(self.recommendations): if idx > len(self.recommendations):
result['error'] = 'bad id' result['error'] = 'bad id'
result['Success'] = False result['Success'] = False
...@@ -644,7 +644,7 @@ class RecommenderXBlock(XBlock): ...@@ -644,7 +644,7 @@ class RecommenderXBlock(XBlock):
resource_id = data['id'] resource_id = data['id']
result = {} result = {}
result['id'] = resource_id result['id'] = resource_id
idx = self.recommenations.index(resource_id) idx = self.recommendations.index(resource_id)
if idx > len(self.recommendations): if idx > len(self.recommendations):
result['error'] = 'bad id' result['error'] = 'bad id'
result['Success'] = False result['Success'] = False
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment