]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/amf_controller.rb
Fix spelling mistake.
[rails.git] / app / controllers / amf_controller.rb
index febc4db68cc6a1464e02c00bd504e739f4a587fd..7f85280b79d29d5b320460d01f028f14727a3fd0 100644 (file)
@@ -29,7 +29,7 @@ class AmfController < ApplicationController
   include Potlatch
 
   session :off
-  before_filter :check_write_availability
+  before_filter :check_api_writable
 
   # Main AMF handlers: process the raw AMF string (using AMF library) and
   # calls each action (private method) accordingly.
@@ -524,10 +524,10 @@ class AmfController < ApplicationController
   end
 
   # Authenticate token
-  # (could be removed if no-one uses the username+password form)
+  # (can also be of form user:pass)
 
   def getuserid(token) #:doc:
-       if (token =~ /^(.+)\+(.+)$/) then
+       if (token =~ /^(.+)\:(.+)$/) then
          user = User.authenticate(:username => $1, :password => $2)
        else
          user = User.authenticate(:token => token)