Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃悰 Some redundant data in serialized entity #396

Open
1 task done
dmekhov opened this issue Feb 20, 2023 · 1 comment
Open
1 task done

馃悰 Some redundant data in serialized entity #396

dmekhov opened this issue Feb 20, 2023 · 1 comment
Assignees
Labels

Comments

@dmekhov
Copy link

dmekhov commented Feb 20, 2023

No duplicates 馃ゲ.

  • I have searched for a similar issue in our bug tracker and didn't find any solutions.

What happened?

This code

$item = $this->repository->findByPK(1);

return $this->response->json(
  [
   'data' => $item
  ]
);

returns

{
  "data": {
    "id": 1,
    "__cycle_orm_rel_map": {},
    "__cycle_orm_relation_props": {},
    "__cycle_orm_rel_data": []
  }
}

I expect that __cycle_orm_* fields will not be displayed

Version

ORM 2.2.2
PHP 8.2
@dmekhov dmekhov added status:to be verified Needs to be reproduced and validated. type:bug Bug labels Feb 20, 2023
@roxblnfk roxblnfk added type:enhancement Enhancement. and removed status:to be verified Needs to be reproduced and validated. labels Feb 21, 2023
@roxblnfk
Copy link
Member

Note
We can use some static or global WeakMap to move the internal properties outside

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Todo
Development

No branches or pull requests

2 participants