if always set to true when adding isset
At first look, this snippet seems to be fine.

    // my_controller.php
    $data['errors'] = (object)$this->session->userdata('errors_registration');
    $this->load->view('registration/my_view',$data);

    // print_r($data['errors'])
    // stdClass Object
    // (
    //    [domain_err] => 0
    //    [wbholder_err] => 0
    //    [methodpayment_err] => 0
    //    [createaccount_err] => 2
    //    [gtc_err] => 0
    // )

    // my_view.php
    if($errors->domain_err == 1) echo "TRUE"; else echo "FALSE"; // FALSE

And when, `$data['errors']` is empty,

    // print_r($data['errors'])
    // stdClass Object
    // (
    //    [scalar] => 
    // )

    // my_view.php
    if($errors->domain_err == 1) echo "TRUE"; else echo "FALSE";

I get this,

> **A PHP Error was encountered** Severity: Notice Message: Undefined property: stdClass::$domain_err

To address the notice, I added `isset()`, making my snippet now to `if(isset($errors->domain_err) == 1)`, however, since this change, the condition seems to be always set to true, thus outputting **TRUE**. Is there other way around to get over the notice while maintaining the conditional output I am expecting?
    

if always set to true when adding isset
===

At first look, this snippet seems to be fine.

    // my_controller.php
    $data['errors'] = (object)$this->session->userdata('errors_registration');
    $this->load->view('registration/my_view',$data);

    // print_r($data['errors'])
    // stdClass Object
    // (
    //    [domain_err] => 0
    //    [wbholder_err] => 0
    //    [methodpayment_err] => 0
    //    [createaccount_err] => 2
    //    [gtc_err] => 0
    // )

    // my_view.php
    if($errors->domain_err == 1) echo "TRUE"; else echo "FALSE"; // FALSE

And when, `$data['errors']` is empty,

    // print_r($data['errors'])
    // stdClass Object
    // (
    //    [scalar] => 
    // )

    // my_view.php
    if($errors->domain_err == 1) echo "TRUE"; else echo "FALSE";

I get this,

> **A PHP Error was encountered** Severity: Notice Message: Undefined property: stdClass::$domain_err

To address the notice, I added `isset()`, making my snippet now to `if(isset($errors->domain_err) == 1)`, however, since this change, the condition seems to be always set to true, thus outputting **TRUE**. Is there other way around to get over the notice while maintaining the conditional output I am expecting?
    
