web3wagers / gostarkme

Fund raising project in Starknet ecosystem
http://web3wagers.github.io/gostarkme/
GNU Affero General Public License v3.0
18 stars 74 forks source link

[feat] Add new asserts to set_reason #253

Closed EmmanuelAR closed 4 days ago

EmmanuelAR commented 1 week ago

This issue will be part of ODHack10, please apply via Onlydust app

petersdt commented 1 week ago

Hi, I'm Peter and I'll be working on issue #253.

I estimate this will take 1hr to complete.

This is how I would tackle this issue:

BrunoAmbricca commented 1 week ago

I would like to work on this issue

josephchimebuka commented 1 week ago

May I try my hand at this?

Immanuelolivia1 commented 1 week ago

Can I take this from here?

Emmanex01 commented 1 week ago

Hi, mind if I take this issue?

mimisavage commented 1 week ago

Can I take this from here?

Benjtalkshow commented 1 week ago

Would love to tackle this!

ryzen-xp commented 1 week ago

Hi, I am proficient Blockchain developer expert in Cairo , Rust and Solidity and also in web development. I have contributed many cairo and rust projects like chaineventt , stark me , arkproject etc . please /assign this issue . Thank You

ShantelPeters commented 1 week ago

Can I try solving this issue?

SoarinSkySagar commented 1 week ago

May I work on this issue @EmmanuelAR?

I am an experienced cairo dev and a regular contributor at @keep-starknet-strange.

eta: 3 days

MullerTheScientist commented 1 week ago

I am a full-stack developer with experience in QA testing and languages like Python, Cairo, Solidity, React, and JavaScript. please can i address this issue

jorgezerpa commented 1 week ago

Hello! Dojo Here⛩️

This is how I will tackle the issue:

I found that the function set_state already have an assert that check that the caller should be an admin. So I will implement a similar logic on the set_reason function. This is how the function will looks when finished:

fn set_reason(ref self: ContractState, reason: ByteArray) {
            let caller = get_caller_address();
            let valid_address_1 = contract_address_const::<FundManagerConstants::VALID_ADDRESS_1>();
            let valid_address_2 = contract_address_const::<FundManagerConstants::VALID_ADDRESS_2>();
            assert!(
                valid_address_1 == caller || valid_address_2 == caller || self.owner.read() == caller,
                "Only Admins or owner can set a reason."
            );
            self.reason.write(reason);
}

Of course If is needed maybe I will remove the owner conditional from the code

ETA: <30min

I'm attentive!

Supa-mega commented 1 week ago

Would love to tackle this!

vestor-dev commented 1 week ago

hey sir I'd like to handle this task. i'm a frontend developer with experience i would really love to contribute to your project kindly assign :)

saimeunt commented 1 week ago

Hey, I'm a returning contributor having previously worked on testing gostarkme, I think this can be completed in half a day.

Gianfranco99 commented 1 week ago

Hello, I can solve this issue easily, I have already been contributing to this project and I would like to continue being part of it!

josephchimebuka commented 1 week ago

Thank you for assigning @EmmanuelAR getting to it ASAP!