-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
avoid false positive from .try(:internal_resource)
Using #try on :internal_resource can yield unexpected results. If the method is undefined, it can return a truthy value instead of the typical nil. E.g. ```ruby Hyrax::FileSet.try(:internal_resource) || 'hi' => #<Dry::Types::Result::Failure input=:internal_resource error=#<Dry::Struct::Error: [Hyrax::FileSet.new] can't convert Symbol into Hash>> ```
- Loading branch information
1 parent
62517e6
commit 5ae4568
Showing
1 changed file
with
50 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters