Feature/bt 1496 identity setup single transaction#142
Feature/bt 1496 identity setup single transaction#142mohamadhammoud merged 12 commits intodevelopfrom
Conversation
pgonday
left a comment
There was a problem hiding this comment.
removeClaimcan be called byCLAIM_ADDERwith theexecutefunction- no check for valid identityType
| } | ||
|
|
||
| // bootstraps an identity: adds claim adder keys, transfers ownership, removes factory key | ||
| function _setupIdentityKeys( |
There was a problem hiding this comment.
to avoid code duplicates i would use this internal function in both identity deployment functions (1 or many management keys). instead of address _owner just put an array of management keys. for the simple deploy function that array only contains the owner address.
| import { ECDSA } from "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; | ||
| import { UUPSUpgradeable } from "@openzeppelin/contracts-upgradeable/proxy/utils/UUPSUpgradeable.sol"; | ||
|
|
||
| contract ClaimIssuer is IClaimIssuer, Identity, UUPSUpgradeable { |
| import { UUPSUpgradeable } from "@openzeppelin/contracts-upgradeable/proxy/utils/UUPSUpgradeable.sol"; | ||
|
|
||
| contract ClaimIssuer is IClaimIssuer, Identity, UUPSUpgradeable { | ||
| mapping(bytes => bool) public revokedClaims; |
| function initialize( | ||
| address initialManagementKey | ||
| address initialManagementKey, | ||
| uint256 |
There was a problem hiding this comment.
linter is not happy here, need to fix it
Changes to gas cost
🧾 Summary (10% most significant diffs)
Full diff report 👇
|
24a5494 to
806a427
Compare
806a427 to
5658e3d
Compare
5658e3d to
da5eb09
Compare
|
please add a function on the gateway that allows the gateway owner to add a token factory address on the IdFactory. The function already exists on the factory but it is not exposed on the gateway |
| override | ||
| initializer | ||
| { | ||
| __ClaimIssuer_init(initialManagementKey); |
There was a problem hiding this comment.
Can't you just do super.initialize(initialManagementKey, IdentityTypes.CLAIM_ISSUER);
and remove __ClaimIssuer_init
There was a problem hiding this comment.
c16f928
We can't use super.initialize() directly because both functions are external, I removed __ClaimIssuer_init entirely and inlined its logic directly into initialize
No description provided.