setScenario()

Hi,

Your thoughts on a setScenario() method?

Example:



$user->setScenario('register');


$user->setAttributes($_POST);





if ($user->save()) {


    // Success ...


}


As opposed to:



$user->setAttributes($_POST, 'register');





if ($user->validate('register')) {


    if ($user->save(false)) {


        // Success ...


    }


}


_da.

Yeah, I actually thought about this. Could you please create a ticket? Thanks.

Quote

Yeah, I actually thought about this. Could you please create a ticket? Thanks.

Done.