Skip to content

Commit df8cb69

Browse files
authored
Merge pull request #10 from BitFinding/dev/maintainability-cleanup
# Maintainability Cleanup
2 parents 6a129fc + c214391 commit df8cb69

6 files changed

Lines changed: 457 additions & 475 deletions

File tree

CONTRIBUTING.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Contributing to Executor Contract
1+
# Contributing to Multiplexer
22

3-
We love your input! We want to make contributing to Executor Contract as easy and transparent as possible, whether it's:
3+
We love your input! We want to make contributing to Multiplexer as easy and transparent as possible, whether it's:
44

55
- Reporting a bug
66
- Discussing the current state of the code
@@ -24,8 +24,8 @@ Pull requests are the best way to propose changes to the codebase. We actively w
2424
## Any contributions you make will be under the MIT Software License
2525
In short, when you submit code changes, your submissions are understood to be under the same [MIT License](http://choosealicense.com/licenses/mit/) that covers the project. Feel free to contact the maintainers if that's a concern.
2626

27-
## Report bugs using Github's [issue tracker](https://github.com/yourusername/executor-contract/issues)
28-
We use GitHub issues to track public bugs. Report a bug by [opening a new issue](https://github.com/yourusername/executor-contract/issues/new); it's that easy!
27+
## Report bugs using Github's [issue tracker](https://github.com/BitFinding/multiplexer/issues)
28+
We use GitHub issues to track public bugs. Report a bug by [opening a new issue](https://github.com/BitFinding/multiplexer/issues/new); it's that easy!
2929

3030
## Write bug reports with detail, background, and sample code
3131

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ readme = "README.md"
1616
alloy-primitives = { version = "1.5.2" }
1717

1818
[dev-dependencies]
19-
tokio = { version = "1.44", features = ["rt", "macros"] }
20-
alloy = { version = "1.2.1", features = ["full", "node-bindings"] }
19+
tokio = { version = "1", features = ["rt", "macros"] }
20+
alloy = { version = "1.7", features = ["full", "node-bindings"] }
2121

2222
[build-dependencies]
2323
hex = "0.4.3"

README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -45,14 +45,14 @@ This example demonstrates how to construct the bytecode for a Morpho flash loan
4545

4646
```rust
4747
use alloy::{
48-
primitives::{address, uint, Address, Bytes, U256, hex},
48+
primitives::{address, uint, Address, U256, hex},
4949
sol,
50-
sol_types::{SolCall},
50+
sol_types::SolCall,
5151
};
52-
use multiplexer::FlowBuilder;
52+
use multiplexer_evm::FlowBuilder;
5353

5454
// Define necessary constants
55-
const ONEHUNDRED_ETH: U256 = uint!(100000000000000000000_U256); // 100e18
55+
const HUNDRED_ETH: U256 = uint!(100000000000000000000_U256); // 100e18
5656
const WETH9: Address = address!("c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2");
5757
const MORPHO: Address = address!("BBBBBbbBBb9cC5e90e3b3Af64bdAF62C37EEFFCb");
5858

@@ -74,9 +74,9 @@ fn generate_morpho_flashloan_flow() -> Vec<u8> {
7474
// It needs to ensure Morpho can pull the funds back.
7575
let approve_calldata = IERC20::approveCall {
7676
spender: MORPHO,
77-
value: ONEHUNDRED_ETH, // Approve the exact loan amount.
78-
// Note: A real flash loan requires approving amount + fee.
79-
// The executor must hold sufficient WETH *before* this approval runs.
77+
value: HUNDRED_ETH, // Approve the exact loan amount.
78+
// Note: A real flash loan requires approving amount + fee.
79+
// The executor must hold sufficient WETH *before* this approval runs.
8080
}.abi_encode();
8181

8282
let inner_flow_bytes = FlowBuilder::empty()
@@ -89,7 +89,7 @@ fn generate_morpho_flashloan_flow() -> Vec<u8> {
8989
// This is the main flow sent to the executor contract transaction.
9090
let flashloan_calldata = IMorpho::flashLoanCall {
9191
token: WETH9, // Asset to borrow
92-
assets: ONEHUNDRED_ETH, // Amount to borrow
92+
assets: HUNDRED_ETH, // Amount to borrow
9393
data: inner_flow_bytes.into(), // Pass the repayment flow as callback data
9494
}.abi_encode();
9595

0 commit comments

Comments
 (0)