mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 16:57:58 +00:00
Offchain testing: Fix reading response (#10294)
This commit is contained in:
@@ -341,7 +341,7 @@ impl offchain::Externalities for TestOffchainExt {
|
||||
Ok(0)
|
||||
} else {
|
||||
let read = std::cmp::min(buffer.len(), response[req.read..].len());
|
||||
buffer[0..read].copy_from_slice(&response[req.read..read]);
|
||||
buffer[0..read].copy_from_slice(&response[req.read..req.read + read]);
|
||||
req.read += read;
|
||||
Ok(read)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user