cargo update

Also updates our gems
This commit is contained in:
Luke Parker
2024-05-21 06:09:04 -04:00
parent a0a7d63dad
commit 400319cd29
6 changed files with 339 additions and 331 deletions

View File

@@ -58,14 +58,7 @@ impl Deployer {
/// Construct a new view of the `Deployer`.
pub async fn new(provider: Arc<RootProvider<SimpleRequest>>) -> Result<Option<Self>, Error> {
let address = Self::address();
#[cfg(not(test))]
let required_block = BlockNumberOrTag::Finalized;
#[cfg(test)]
let required_block = BlockNumberOrTag::Latest;
let code = provider
.get_code_at(address.into(), required_block.into())
.await
.map_err(|_| Error::ConnectionError)?;
let code = provider.get_code_at(address.into()).await.map_err(|_| Error::ConnectionError)?;
// Contract has yet to be deployed
if code.is_empty() {
return Ok(None);