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

Added ability to manually assign an ID before saving a new entity #261

Merged
merged 2 commits into from
Oct 25, 2018

Conversation

adrians5j
Copy link
Member

@adrians5j adrians5j commented Oct 25, 2018

If for some reason you would like to manually assign an ID (instead of receiving an automatic and randomly generated one), you can now assign it by yourself, before you call save and it will be used.

Just make sure it's a valid ID (MongoDB format) - ^[0-9a-fA-F]{24}$. Otherwise an error will be thrown.

@adrians5j adrians5j self-assigned this Oct 25, 2018
@adrians5j adrians5j merged commit a75949a into development Oct 25, 2018
@adrians5j adrians5j deleted the entity/manualIdAssign branch October 25, 2018 17:18
@coveralls
Copy link

Coverage Status

Coverage increased (+0.008%) to 94.969% when pulling 1bc6604 on entity/manualIdAssign into c4741a0 on development.

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

Successfully merging this pull request may close these issues.

2 participants