Skip to content

Commit

Permalink
require open-uri for fetching URL
Browse files Browse the repository at this point in the history
  • Loading branch information
locks committed Jan 27, 2018
1 parent 4aa16ed commit 917ae77
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/versions.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ def registered(app)
module Helpers

def current_version
require 'open-uri'
versions = JSON.parse(open('https://raw.githubusercontent.com/emberjs/guides.emberjs.com/master/snapshots/versions.json').read)
versions.sort_by! { |version| Gem::Version.new(version[1..-1]) }
@current_version = versions.last
Expand Down

0 comments on commit 917ae77

Please sign in to comment.