What's the proper way to determine the environment? Right now I'm using:
class Main < Sinatra::Base
get '/' do
puts self.class.development?
puts self.class.production?
end
end
But it doesn't seem right.
I would use Sinatra::Base.development?
or Sinatra::Base.production?
since that is where the methods are coming from.