Skip to content

Code for stacks - #2

Open
blessychoco wants to merge 6 commits into
mainfrom
code-for-stacks
Open

Code for stacks#2
blessychoco wants to merge 6 commits into
mainfrom
code-for-stacks

Conversation

@blessychoco

Copy link
Copy Markdown
Owner

Optimize IP Registration Expiration Extension

Description
This pull request enhances the functionality of the Intellectual Property Protection Smart Contract by optimizing the expiration extension feature. The main changes focus on improving the extend-ip-registration function to make it more robust and flexible.

Changes

  1. Modified the extend-ip-registration function to handle both cases of IPs with and without existing expiration dates.
  2. Improved input validation and error handling in the expiration extension process.
  3. Ensured type consistency in the match expression within the extend-ip-registration function.

Detailed Changes

  • Updated the extend-ip-registration function to:
    • Allow setting an expiration for IPs that didn't have one before.
    • Ensure the new expiration date is always in the future.
    • Verify that only the owner can extend the expiration.
    • For IPs with an existing expiration, ensure the new date is later than the current one.

Impact
These changes provide a more flexible and secure way to manage IP expirations in the smart contract. Users can now extend expirations for all registered IPs, regardless of whether they initially had an expiration date set.

Additional Notes
This update maintains backwards compatibility with existing IP registrations while providing enhanced functionality for expiration management.

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.

1 participant