lib/nicoquery/object_mapper/video_array.rb in nicoquery-0.1.8.8 vs lib/nicoquery/object_mapper/video_array.rb in nicoquery-0.1.8.9
- old
+ new
@@ -93,10 +93,12 @@
end
def tags
tag_obj = @hash['tags']['tag_info']
- if tag_obj.instance_of? Array
+ if tag_obj.nil?
+ tag_array = []
+ elsif tag_obj.instance_of? Array
tag_array = tag_obj
else
tag_array = [ tag_obj ]
end