Skip to content

Commit c9b0679

Browse files
committed
Updated code to reflect latest gem interface
1 parent 6d2d908 commit c9b0679

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

Gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
source 'http://rubygems.org'
22
ruby "2.6.6"
33
gem 'sinatra'
4-
gem 'githubchart', '>= 3.2.0'
4+
gem 'githubchart', '>= 3.3.1'

Gemfile.lock

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@ GEM
22
remote: http://rubygems.org/
33
specs:
44
basiccache (1.0.0)
5-
githubchart (3.2.0)
6-
githubstats (~> 3.1.0)
5+
githubchart (3.3.1)
6+
githubstats (~> 3.2.0)
77
svgplot (~> 1.0.0)
8-
githubstats (3.1.0)
8+
githubstats (3.2.0)
99
basiccache (~> 1.0.0)
1010
nokogiri (~> 1.10.8)
1111
mini_portile2 (2.4.0)
@@ -25,7 +25,7 @@ PLATFORMS
2525
ruby
2626

2727
DEPENDENCIES
28-
githubchart (>= 3.2.0)
28+
githubchart (>= 3.3.1)
2929
sinatra
3030

3131
RUBY VERSION

app.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
headers 'Cache-Control' => "max-age=#{60*60*24}"
1919

2020
username = params[:username].chomp('.svg') #Chomp off the .svg extension to be backwards compatible
21-
svg = GithubChart.new(user: username).svg
21+
svg = GithubChart.new(user: username).render('svg')
2222
stream do |out|
2323
out << svg
2424
end
@@ -39,7 +39,7 @@
3939
scheme = ['#EEEEEE', lighten_color(base_color, 0.3), lighten_color(base_color, 0.2), base_color, darken_color(base_color, 0.8)]
4040
end
4141

42-
svg = GithubChart.new(user: username, colors: scheme).svg
42+
svg = GithubChart.new(user: username, colors: scheme).render('svg')
4343
stream do |out|
4444
out << svg
4545
end

0 commit comments

Comments
 (0)