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

json & jsonb constraints support #36

Open
marocchino opened this issue May 7, 2018 · 1 comment
Open

json & jsonb constraints support #36

marocchino opened this issue May 7, 2018 · 1 comment

Comments

@marocchino
Copy link
Contributor

Hi, I want some constraints to json just like this.

Unfortunately, current version can not receive something like jsontable(((j->>'uuid')::uuid)) because of this wrapper.

rein/lib/rein/util.rb

Lines 17 to 21 in f529894

if /^".*"$/.match?(attribute)
attribute
else
"\"#{attribute}\""
end

If you don't mind, I want make PR for it. how do you think?

@nullobject
Copy link
Owner

Sure, if you're happy to make a PR please go ahead 😄

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