Skip to content

Commit

Permalink
hound
Browse files Browse the repository at this point in the history
  • Loading branch information
gemfarmer committed Oct 27, 2016
1 parent c76c8ed commit 9ca776d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions _plugins/redcarpet.rb
Original file line number Diff line number Diff line change
Expand Up @@ -37,19 +37,19 @@ def header(title, level)
# SiteHeaders.add updates the array, @current_headers
# SiteHeaders.clear clears the @current_headers array
class SiteHeaders
def initialize()
def initialize
@current_headers ||= []
end

def self.current
@current_headers
end

def self.add item
def self.add(item)
if @current_headers
@current_headers << item
@current_headers << item
else
@current_headers = [item]
@current_headers = [item]
end
end

Expand Down

0 comments on commit 9ca776d

Please sign in to comment.