fnp
/
wolnelektury.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use actual sync for bookmarks.
[wolnelektury.git]
/
src
/
catalogue
/
api
/
views.py
diff --git
a/src/catalogue/api/views.py
b/src/catalogue/api/views.py
index
941b122
..
0f3a95f
100644
(file)
--- a/
src/catalogue/api/views.py
+++ b/
src/catalogue/api/views.py
@@
-257,7
+257,10
@@
class BookSyncView(RetrieveAPIView):
def retrieve(self, request, *args, **kwargs):
instance = self.get_object()
def retrieve(self, request, *args, **kwargs):
instance = self.get_object()
- return Response(json.loads(instance.get_sync()))
+ return Response([
+ {"id": i, "timestamp": ts}
+ for (i, ts) in instance.get_sync()
+ ])
@vary_on_auth # Because of embargo links.
@vary_on_auth # Because of embargo links.