I have an array of data:
Array ( [0] => stdClass Object
(
[name] => admin
[email] => [email protected]
[password] => cxvxvcxvcxv
)
)
I want to add a new data to this array so the final array looks like:
Array( [0] => stdClass Object
(
[name] => admin
[email] => [email protected]
[password] => cxvxvcxvcxv
[enabled] => true
)
)
I tried array_merge(), but it gives me result like this:
Array( [0] => stdClass Object
(
[name] => admin
[email] => [email protected]
[password] => cxvxvcxvcxv
)
[enabled] => true
)
How do I achieve the result I want?