From 05e9e3194175cb5e26d6933a6232c2399c4639d0 Mon Sep 17 00:00:00 2001 From: Joseph Schorr Date: Wed, 25 Jan 2017 12:55:56 -0500 Subject: [PATCH] Fix small lookup bug under MySQL --- endpoints/api/repository.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/endpoints/api/repository.py b/endpoints/api/repository.py index ec80269b1..1ae77b6a2 100644 --- a/endpoints/api/repository.py +++ b/endpoints/api/repository.py @@ -218,7 +218,7 @@ class RepositoryList(ApiResource): repo['last_modified'] = last_modified_map.get(repo_id) if parsed_args['popularity']: - repo['popularity'] = action_sum_map.get(repo_id, 0) + repo['popularity'] = float(action_sum_map.get(repo_id, 0)) if username: repo['is_starred'] = repo_id in star_set