Skip to content

Commit

Permalink
Make ic a class variable, rather than an instance variable.
Browse files Browse the repository at this point in the history
  • Loading branch information
nogweii committed Feb 16, 2010
1 parent 3cc750c commit 06223f7
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions pummel.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,12 @@
$: << File.join(File.dirname(__FILE__), 'vendor', 'ruby-oembed', 'lib')
require 'oembed'

@@rss_url = "http://feeds.pinboard.in/rss/u:evaryont/"
@@ic = Iconv.new('UTF-8//IGNORE', 'UTF-8')
def refresh_rss
valid_string = @ic.iconv(open(@@rss_url).read << ' ')[0..-2]
valid_string = @@ic.iconv(open(@@rss_url).read << ' ')[0..-2]
@@rss = RSS::Parser.parse valid_string, false
end

@@rss_url = "http://feeds.pinboard.in/rss/u:evaryont/"
@ic = Iconv.new('UTF-8//IGNORE', 'UTF-8')
refresh_rss()

set :public, File.dirname(__FILE__) + '/public'
Expand Down

0 comments on commit 06223f7

Please sign in to comment.