Sha256: 5a38e4cd5f62d28613d486fce2ee3234516587a1f6e50d6ee972bb2f6e1fa5e2

Contents?: true

Size: 364 Bytes

Versions: 1

Compression:

Stored size: 364 Bytes

Contents

module Ryakuzu
  class RootController < ActionController::Base
    rescue_from Errno::ENOENT, with: :render_500
    helper_method :schema_present?

    private

    def render_500
      render template: 'ryakuzu/main/error_500', layout: 'ryakuzu/layouts/application', status: 500
    end

    def schema_present?
      File.file?('db/schema.rb')
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
ryakuzu-0.2.6 app/controllers/ryakuzu/root_controller.rb