Rename AdvertiseStorageLastId to AdvertiseStorageRecentBlockHash

This commit is contained in:
Michael Vines
2019-03-02 09:46:19 -08:00
committed by Greg Fitzgerald
parent 0743f54dfe
commit ea110efabd
3 changed files with 9 additions and 9 deletions

View File

@ -83,7 +83,7 @@ fn entrypoint(
};
storage_account_state.proofs[segment_index].push(proof_info);
}
StorageProgram::AdvertiseStorageLastId { id, entry_height } => {
StorageProgram::AdvertiseStorageRecentBlockHash { hash, entry_height } => {
let original_segments = storage_account_state.entry_height / ENTRIES_PER_SEGMENT;
let segments = entry_height / ENTRIES_PER_SEGMENT;
debug!(
@ -95,7 +95,7 @@ fn entrypoint(
}
storage_account_state.entry_height = entry_height;
storage_account_state.id = id;
storage_account_state.hash = hash;
// move the proofs to previous_proofs
storage_account_state.previous_proofs = storage_account_state.proofs.clone();

View File

@ -30,7 +30,7 @@ fn get_storage_last_id(bank: &Bank, account: Pubkey) -> Hash {
let state = deserialize(&storage_system_account.userdata);
if let Ok(state) = state {
let state: storage_program::StorageProgramState = state;
return state.id;
return state.hash;
}
}
Hash::default()