lib/linodians.rb in linodians-1.1.0 vs lib/linodians.rb in linodians-1.1.1

- old
+ new

@@ -1,6 +1,7 @@ # frozen_string_literal: true + require 'open-uri' require 'nokogiri' ## # Module for parsing Linode employee info @@ -26,10 +27,11 @@ parse_user(username, block).merge parse_social(block) end end def raw_data - Nokogiri::HTML(open(DATA_URL)).css('div').map do |block| + page = open(DATA_URL) # rubocop:disable Security/Open + Nokogiri::HTML(page).css('div').map do |block| internal_block = block.at_xpath('div/div[@class="employee-display"]') next unless internal_block [block[:id], internal_block] end.compact end