X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/63303c22b704ca290c16ae908da1324f3ea25b2c..30a01fb7f9dedc757a27f9bf97e3d720f4530508:/app/controllers/site_controller.rb diff --git a/app/controllers/site_controller.rb b/app/controllers/site_controller.rb index a05fe376b..5fb8aa111 100644 --- a/app/controllers/site_controller.rb +++ b/app/controllers/site_controller.rb @@ -113,7 +113,14 @@ class SiteController < ApplicationController def export; end - def offline; end + def offline + flash.now[:warning] = if Settings.status == "database_offline" + t("layouts.osm_offline") + else + t("layouts.osm_read_only") + end + render :html => nil, :layout => true + end def preview render :html => RichText.new(params[:type], params[:text]).to_html