Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extending/adding entities #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

svskaushik
Copy link

I extended some of the existing entities with more fields and created a few new ones based on emitted events mentioned in Lens' docs

I'd appreciate some feedback on whether such additions are in line with what is planned for this subgraph or whether there's stuff I should tweak and anything else.

Thanks

@lancenonce
Copy link

Hi @svskaushik , these entities look clean, I'm confused about the whitelisting entities like ProfileCreatorWhitelisted, FollowModuleWhitelist, ReferenceModuleWhitelist, and CollectModuleWhitelist. Are these in place to verify the user is whitelisted for the Lens Protocol? Or can users make their own whitelists?

@svskaushik
Copy link
Author

svskaushik commented May 28, 2022

Hi @lndavis6, thanks for taking the time to look through!
Yes, the idea behind the whitelisting entities was to keep a track of whether users are whitelisted for Lens (indexing the whitelisting events from the contract)

An example of the intended return values below if it helps.
A query for profileCreatorWhitelist for the address 0x39c9bc23b1f993b94dec69b7ac11c95145ec4e15 returns the following:

{
  "data": {
    "profileCreatorWhitelists": [
      {
        "id": "0x39c9bc23b1f993b94dec69b7ac11c95145ec4e15",
        "isWhitelisted": true,
        "lastUpdated": "1649155635"
      }
    ]
  }
}

(this is from a test contract on mumbai)
I guess these would just serve a similar purpose as directly reading isProfileCreatorWhitelisted from the contract, with the additional timestamp.

I hope that helps a little

@lancenonce
Copy link

Makes sense! Thank you @svskaushik

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

Successfully merging this pull request may close these issues.

2 participants