Skip to content
This repository has been archived by the owner on May 23, 2019. It is now read-only.

Change syntax of "next" in get_commonality_of_user for py2neo v4 #24

Open
seanofahey opened this issue Dec 26, 2018 · 0 comments
Open

Comments

@seanofahey
Copy link

First thanks for the code and tutorial -- they are both very helpful.

Issue:

  • When logged in as a user and looking at the profile page of another user, the system does not correctly display the number of likes or the common tags.

Potential Cause:

  • the return call on the get_commonality_of_user method in models.py uses the following syntax:

return graph.run(query, they=other.username, you=self.username).next

Fix:
Modify the return call to be:
return graph.run(query, they=other.username, you=self.username).next()

or wrap it with:
return next(graph.run(query, they=other.username, you=self.username))

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant