Permalink
Browse files

fixing issue with Tilt::VERSION check: '0.10' < '0.8'

  • Loading branch information...
1 parent d987108 commit 91b740afa8dff24b895cc35d59918de4fc60275f @rkh committed May 30, 2010
Showing with 2 additions and 1 deletion.
  1. +2 −1 lib/sinatra/base.rb
View
@@ -8,7 +8,8 @@
# require tilt if available; fall back on bundled version.
begin
require 'tilt'
- if Tilt::VERSION < '0.8'
+ major, minor = Tilt::VERSION.split('.').map { |e| e.to_i }
+ if major < 0 and minor < 8
warn "WARN: sinatra requires tilt >= 0.8; you have #{Tilt::VERSION}. " +
"loading bundled version..."
Object.send :remove_const, :Tilt

0 comments on commit 91b740a

Please sign in to comment.