Skip to content

Commit

Permalink
allow StaticFile#close to be called multiple times
Browse files Browse the repository at this point in the history
  • Loading branch information
rkh committed Jun 10, 2011
1 parent b727870 commit 66fac5b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/sinatra/base.rb
Expand Up @@ -284,6 +284,10 @@ def byte_ranges(env, size)
ranges
end

def close
super unless closed?
end

CHUNK_SIZE = 8192

def each
Expand Down

0 comments on commit 66fac5b

Please sign in to comment.