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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

- There must be a primary key property named '_id' on a synchronized Realm but none was found for type 'RLMOptional' #64

Closed
abaig-experlabs opened this issue Nov 26, 2021 · 4 comments

Comments

@abaig-experlabs
Copy link

abaig-experlabs commented Nov 26, 2021

Hey I am facing this issue while trying to add data with realm swift
is RLMOptional a custom data type of unrealm?
@arturdev

@arturdev
Copy link
Collaborator

Hi. No, RLMOptional is one of the Realm's native types

@abaig-experlabs
Copy link
Author

abaig-experlabs commented Nov 26, 2021

Hi, do you have any idea why I get this error?
@arturdev

@abaig-experlabs
Copy link
Author

i just debugged a little and it seems like the unrealm is treating optional custom objects like this which is causing the error
@arturdev

Screen Shot 2021-11-26 at 7 34 08 PM

@arturdev
Copy link
Collaborator

So far my unit tests pass successfully:
https://github.com/arturdev/Unrealm/blob/master/Example/Tests/ExampleModels/User.swift#L25

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

No branches or pull requests

2 participants