fix for sinatra 1.4 compatibility issue.