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

Contract pausing #6

Merged
merged 4 commits into from
Apr 30, 2024
Merged

Contract pausing #6

merged 4 commits into from
Apr 30, 2024

Conversation

MissingNO57
Copy link
Collaborator

No description provided.

@MissingNO57 MissingNO57 requested a review from pbukva April 23, 2024 10:24
@@ -0,0 +1,3 @@
pub fn option_to_string<T: ToString>(value: Option<T>) -> String {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This is usable sometimes in contract events and attributes when we want to convert Option<T> to string, so it says "none" when None and does .to_string() for Some case.

@@ -1,6 +1,8 @@
use cosmwasm_std::{Addr, Deps, Env};
use cosmwasm_std::{StdError, StdResult};

const ERR_NOT_SUPER_ADMIN: &str = "[FET_ERR_NOT_SUPER_ADMIN] Sender is not a super-admin.";
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Unified error handling, I think we should be using this convention everywhere.

src/pausing/storage.rs Outdated Show resolved Hide resolved
Copy link
Collaborator

@pbukva pbukva left a comment

Choose a reason for hiding this comment

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

See the inline comment

@MissingNO57 MissingNO57 requested a review from pbukva April 29, 2024 13:28
Copy link
Collaborator

@pbukva pbukva left a comment

Choose a reason for hiding this comment

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

LGTM

@MissingNO57 MissingNO57 merged commit a9fa7e4 into main Apr 30, 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.

2 participants