Skip to content

Commit

Permalink
Merge pull request #39 from Cardinal-Cryptography/closebrush
Browse files Browse the repository at this point in the history
A0-2991: Remove OpenBrush from AMM
  • Loading branch information
h4nsu authored Oct 16, 2023
2 parents 579f0b7 + 0233d4b commit 3344ebc
Show file tree
Hide file tree
Showing 29 changed files with 948 additions and 1,800 deletions.
59 changes: 24 additions & 35 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion amm/contracts/factory/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ink = { version = "=4.3.0", default-features = false }
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = [
"derive",
] }
scale-info = { version = "2.3", default-features = false, features = [
scale-info = { version = "2.9", default-features = false, features = [
"derive",
], optional = true }

Expand Down
15 changes: 8 additions & 7 deletions amm/contracts/pair/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,18 @@ ink = { version = "=4.3.0", default-features = false }
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = [
"derive",
] }
scale-info = { version = "2.3", default-features = false, features = [
scale-info = { version = "2.9", default-features = false, features = [
"derive",
], optional = true }

openbrush = { version = "3.2.0", default-features = false, features = [
"psp22",
"reentrancy_guard",
] }
psp22 = { git = "https://github.com/Cardinal-Cryptography/PSP22.git", default-features = false, features = [
"mintable",
"burnable",
]}

amm = { path = "../../logics", default-features = false }
amm-helpers = { path = "../../../helpers", default-features = false }
primitive-types = { version = "0.11.1", default-features = false, features = [
primitive-types = { version = "0.12.1", default-features = false, features = [
"codec",
] }
sp-arithmetic = { version = "18.0.0", default-features = false }
Expand All @@ -36,7 +37,7 @@ std = [
"ink/std",
"scale/std",
"scale-info/std",
"openbrush/std",
"psp22/std",
"amm/std",
"amm-helpers/std",
]
Expand Down
12 changes: 5 additions & 7 deletions amm/logics/impls/pair/data.rs → amm/contracts/pair/data.rs
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
use crate::helpers::ZERO_ADDRESS;
use amm_helpers::types::WrappedU256;
use openbrush::traits::{
AccountId,
use amm::{
helpers::ZERO_ADDRESS,
Balance,
Timestamp,
};
use amm_helpers::types::WrappedU256;
use ink::primitives::AccountId;

pub const STORAGE_KEY: u32 = openbrush::storage_unique_key!(Data);

#[ink::storage_item]
#[derive(Debug)]
#[openbrush::upgradeable_storage(STORAGE_KEY)]
pub struct Data {
pub factory: AccountId,
pub token_0: AccountId,
Expand Down
Loading

0 comments on commit 3344ebc

Please sign in to comment.