Add docstring for rating_package_get

This commit is contained in:
Mark Gregson 2016-12-01 15:50:19 +11:00
parent 993cee3323
commit 246b7140db
1 changed files with 10 additions and 0 deletions

View File

@ -51,6 +51,16 @@ def rating_package_create(context, data_dict):
return Rating.get_package_rating(package.id)
def rating_package_get(context, data_dict):
'''
Get the rating and count of ratings for a package.
Returns a dictionary containing rating and ratings counts.
:param package_id: the id of the package
:type package_id: string
:rtype: dictionary
'''
package_id = data_dict.get('package_id')
error = None