We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f869967 commit f5af464Copy full SHA for f5af464
sysvar/src/epoch_schedule.rs
@@ -170,8 +170,12 @@ impl PodEpochSchedule {
170
u64::from_le_bytes(self.leader_schedule_slot_offset)
171
}
172
173
- pub fn warmup(&self) -> bool {
174
- self.warmup != 0
+ pub fn warmup(&self) -> Result<bool, ProgramError> {
+ match self.warmup {
175
+ 0 => Ok(false),
176
+ 1 => Ok(true),
177
+ _ => Err(ProgramError::InvalidAccountData),
178
+ }
179
180
181
pub fn first_normal_epoch(&self) -> u64 {
0 commit comments