Skip to content

Commit

Permalink
scarb fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
mubarak23 committed May 29, 2024
1 parent 4c82191 commit 7abcc89
Showing 1 changed file with 7 additions and 12 deletions.
19 changes: 7 additions & 12 deletions onchain/src/social/account.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,19 @@ pub trait ISocialAccount<TContractState> {

#[starknet::contract]
pub mod SocialAccount {
use openzeppelin::account::interface;
use openzeppelin::account::AccountComponent;
use openzeppelin::account::AccountComponent;
use openzeppelin::account::interface::ISRC6;
use openzeppelin::account::interface;
use openzeppelin::account::utils::{execute_calls, is_valid_stark_signature};
use openzeppelin::introspection::interface::ISRC5;

use openzeppelin::token::erc20::interface::{ERC20ABIDispatcher, ERC20ABIDispatcherTrait};
use openzeppelin::token::erc20::interface::{IERC20Dispatcher, IERC20DispatcherTrait};
use starknet::account::Call;
use openzeppelin::account::utils::{execute_calls, is_valid_stark_signature};
use starknet::get_caller_address;
use starknet::get_contract_address;
use starknet::get_tx_info;

use openzeppelin::token::erc20::interface::{ERC20ABIDispatcher, ERC20ABIDispatcherTrait};

use super::super::request::{
SocialRequest, SocialRequestImpl, SocialRequestTrait, Encode, Signature
};
Expand All @@ -38,24 +38,19 @@ pub mod SocialAccount {
component!(path: AccountComponent, storage: account, event: AccountEvent);



#[storage]
struct Storage {
#[key]
public_key: u256,


#[substorage(v0)]
account: AccountComponent::Storage,

transfers: LegacyMap<u256, bool>,
}

#[event]
#[derive(Drop, starknet::Event)]
enum Event {
AccountCreated: AccountCreated,

#[flat]
AccountEvent: AccountComponent::Event,
}
Expand Down Expand Up @@ -104,7 +99,7 @@ pub mod SocialAccount {
#[abi(embed_v0)]
impl SRC6Impl of ISRC6<ContractState> {
fn __execute__(self: @ContractState, mut calls: Array<Call>) -> Array<Span<felt252>> {
execute_calls(calls)
execute_calls(calls)
}

fn __validate__(self: @ContractState, mut calls: Array<Call>) -> felt252 {
Expand Down Expand Up @@ -272,4 +267,4 @@ mod tests {

sender.handle_transfer(request);
}
}
}

0 comments on commit 7abcc89

Please sign in to comment.