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

feat: map permission and permissions docs section #436

Merged
merged 7 commits into from
May 21, 2024

Conversation

CJ42
Copy link
Collaborator

@CJ42 CJ42 commented May 13, 2024

What kind of change does this PR introduce (bug fix, feature, docs update, ...)?

✨ Feature

What is the current behaviour (you can also link to an open issue here)?

The function mapPermission can be useful to retrieve the bytes32 hex value of a permission given its name. However, it is not available.

What is the new behaviour (if this is a feature change)?

Export the mapPermission function to make it available in the library + refactor it to return null when the permission name is not known instead of throwing an error.

@CJ42 CJ42 force-pushed the feat/map-permission-and-permissions-docs-section branch from db23a9d to c447bba Compare May 13, 2024 16:55
@CJ42 CJ42 changed the title Feat/map permission and permissions docs section feat: map permission and permissions docs section May 13, 2024
@CJ42 CJ42 marked this pull request as draft May 13, 2024 16:58
```js
import { isDataAuthentic } from '@erc725/erc725.js';

isDataAuthentic(data, verificationOptions);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note this will not always work for the decoded json data unfortunately. If the checksum was pretty printed then the data needs to be the byte array of the file.

@CJ42 CJ42 force-pushed the feat/map-permission-and-permissions-docs-section branch from c447bba to 18b8a93 Compare May 17, 2024 07:20
@CJ42 CJ42 marked this pull request as ready for review May 17, 2024 07:21
@CJ42 CJ42 force-pushed the feat/map-permission-and-permissions-docs-section branch from 18b8a93 to 5e300f0 Compare May 17, 2024 07:22
@CJ42 CJ42 force-pushed the feat/map-permission-and-permissions-docs-section branch from 5e300f0 to 8b2bb98 Compare May 17, 2024 07:26
Copy link
Contributor

@Hugoo Hugoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see the docs are already live for this feature:

https://docs.lukso.tech/tools/erc725js/methods#mappermission

@Hugoo Hugoo merged commit b1784ef into develop May 21, 2024
2 checks passed
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.

3 participants