Change accumulated reward to Option, migrate delegations (#1147)
* Change accumulated reward to Option, migrate delegations * Remove interval from the validator cache * Add info to db errors * Remove interval fetch from the contract * Rework epochs * Fix undelegation errors * Emit error event instead of error * make no-clippy * Fix clippy lints
This commit is contained in:
@@ -239,7 +239,7 @@ pub enum ValidatorApiStorageError {
|
||||
GatewayUptimeHistoryNotFound(String),
|
||||
|
||||
// I don't think we want to expose errors to the user about what really happened
|
||||
InternalDatabaseError,
|
||||
InternalDatabaseError(String),
|
||||
}
|
||||
|
||||
impl Display for ValidatorApiStorageError {
|
||||
@@ -265,8 +265,8 @@ impl Display for ValidatorApiStorageError {
|
||||
"Could not find uptime history associated with gateway {}",
|
||||
identity
|
||||
),
|
||||
ValidatorApiStorageError::InternalDatabaseError => {
|
||||
write!(f, "The internal database has experienced an issue")
|
||||
ValidatorApiStorageError::InternalDatabaseError(err) => {
|
||||
write!(f, "The internal database has experienced an issue: {err}")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user