lib/gaffe/errors.rb in gaffe-0.2 vs lib/gaffe/errors.rb in gaffe-0.2.1

- old
+ new

@@ -7,11 +7,15 @@ before_filter :append_view_paths layout 'error' end def show - render "errors/#{@rescue_response}", status: @status_code + begin + render "errors/#{@rescue_response}", status: @status_code + rescue ActionView::MissingTemplate + render "errors/internal_server_error", status: 500 + end end protected def fetch_exception @@ -21,9 +25,9 @@ end private def append_view_paths - append_view_path File.expand_path('../../../app/views', __FILE__) + append_view_path Gaffe.root.join('app/views') end end end