tap: read_formula_list JSON file can be an array

This commit is contained in:
Jonathan Chang 2020-11-27 17:45:42 +11:00
parent ed73d5b635
commit a39344e7e3

View File

@ -632,7 +632,7 @@ class Tap
end
end
sig { params(file: Pathname).returns(Hash) }
sig { params(file: Pathname).returns(T.any(T::Array[String], Hash)) }
def read_formula_list(file)
JSON.parse file.read
rescue JSON::ParserError