Skip to content

Commit

Permalink
Merge pull request #1017 from ninoseki/improve-type-check
Browse files Browse the repository at this point in the history
refactor: improve type check
  • Loading branch information
ninoseki authored Jan 13, 2024
2 parents 71fdbd6 + 0b91a12 commit e8d713e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docs/analyzers/feed.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ json: ...

### JSON

`json` (`hash`) is an JSON body. Optional.
`json` (`hash`) is a JSON data. Optional.

## Examples

Expand Down
2 changes: 1 addition & 1 deletion lib/mihari/services/feed.rb
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ def call(input_enumerator, selector)
input_enumerator.instance_eval(selector)
end.call

raise TypeError unless parsed.all?(String)
raise TypeError unless parsed.is_a?(Array) || parsed.all?(String)

parsed
end
Expand Down

0 comments on commit e8d713e

Please sign in to comment.