]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/oauth_clients_controller.rb
Set OpenGraph properties hash in diary entry show action
[rails.git] / app / controllers / oauth_clients_controller.rb
index 44dacde6d72a4ce3a19eb7732eedea58d7c13f7d..42b0921f1f62eedfa6c162cc6b0de5ea613e13fd 100644 (file)
@@ -19,7 +19,12 @@ class OauthClientsController < ApplicationController
   end
 
   def new
-    @client_application = ClientApplication.new
+    if Settings.oauth_10_registration
+      @client_application = ClientApplication.new
+    else
+      flash[:error] = t ".disabled"
+      redirect_to :action => "index"
+    end
   end
 
   def edit