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

Fix missing block when using valid? method #174

Merged
merged 1 commit into from
Oct 27, 2022

Conversation

kukicola
Copy link
Contributor

No description provided.

@kukicola
Copy link
Contributor Author

Hello @igorkasyanchuk @gr8bit
Today, I wanted to update my app to use processable_image validator I've recently added but unfortunately, it's rising error:

     LocalJumpError:
       no block given (yield)
     # /Users/kukicola/.asdf/installs/ruby/3.1.2/lib/ruby/gems/3.1.0/gems/active_storage_validations-1.0.2/lib/active_storage_validations/metadata.rb:93:in `read_image'

Not sure why tests didn't fail

@gr8bit
Copy link
Collaborator

gr8bit commented Oct 24, 2022

That's strange... I know almost nobody likes this, but could you please add a test for this condition so this error won't have a chance to reappear in the future? :)

@kukicola
Copy link
Contributor Author

@gr8bit done, tests will fail without if block_given?

@iainbeeston
Copy link
Contributor

Is it possible to get this merged? I'm getting the same issue with the processable_image validator

@gr8bit gr8bit merged commit 97a06fb into igorkasyanchuk:master Oct 27, 2022
@gr8bit
Copy link
Collaborator

gr8bit commented Oct 27, 2022

Is it possible to get this merged? I'm getting the same issue with the processable_image validator

Yes, sorry. I reviewed it tested it and forgot to merge afterwards.

@igorkasyanchuk this should be relevant enough for a gem release as it fixes a common error. :)

@igorkasyanchuk
Copy link
Owner

active_storage_validations-1.0.3.gem released! thanks!

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.

4 participants