-
Notifications
You must be signed in to change notification settings - Fork 19
Hotfix/22f5cb7 #2349
Hotfix/22f5cb7 #2349
Changes from 6 commits
de1ec45
22f5cb7
5eef0cd
6ba905c
4c1d4c5
58a1c2c
b8bd32a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| --- | ||
| "@ensnode/ensnode-sdk": patch | ||
| --- | ||
|
|
||
| Fix boundary gap in `isRegistrationInGracePeriod`: the grace-period upper bound is now inclusive (`>=`) so that `isRegistrationInGracePeriod` and `isRegistrationFullyExpired` are complementary at `now == expiry + gracePeriod`. | ||
|
tk-o marked this conversation as resolved.
Outdated
|
||
This file was deleted.
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -103,10 +103,15 @@ export default function () { | |||||||||
| `Invariant(ENSv2Registry:Label[Registered|Reserved]): Existing unexpired Registration found, expected none or expired.\n${toJson(registration, { pretty: true })}`, | ||||||||||
| ); | ||||||||||
| } | ||||||||||
| } else { | ||||||||||
| // Invariant: if this is a Registration, unless it is a Reservation, it should be fully expired | ||||||||||
| } else if (registration) { | ||||||||||
| // There's an existing Registration, so we need to handle it carefully. | ||||||||||
| // For a reverse name registration, the registrant ID value is guaranteed to end with the label value. | ||||||||||
| const isReverseNameRegistration = | ||||||||||
| registration?.registrantId && registration.registrantId === `0x${label}`; | ||||||||||
|
Comment on lines
+109
to
+110
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value Optional: simplify Since - const isReverseNameRegistration =
- registration?.registrantId && registration.registrantId === `0x${label}`;
+ const isReverseNameRegistration =
+ registration.registrantId === `0x${label}`;
📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||
|
|
||||||||||
|
tk-o marked this conversation as resolved.
Comment on lines
+107
to
+111
|
||||||||||
| // Invariant: if this is a Registration, unless it is a Reservation or a reverse name Registration, it should be fully expired | ||||||||||
|
tk-o marked this conversation as resolved.
|
||||||||||
| if ( | ||||||||||
| registration && | ||||||||||
| !isReverseNameRegistration && | ||||||||||
| registration.type !== "ENSv2RegistryReservation" && | ||||||||||
| !isRegistrationFullyExpired(registration, event.block.timestamp) | ||||||||||
| ) { | ||||||||||
|
|
||||||||||
Uh oh!
There was an error while loading. Please reload this page.