]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/oauth_controller.rb
Merge branch 'master' into openID
[rails.git] / app / controllers / oauth_controller.rb
index 98075b8f810d40bf9cdd6faf8012095e4d0aed3f..4b539b1fdc879207eca038bdfe59e31be2b429ff 100644 (file)
@@ -38,7 +38,7 @@ class OauthController < ApplicationController
 
   def oauthorize
     @token = RequestToken.find_by_token params[:oauth_token]
-    unless @token.invalidated?
+    unless @token.nil? or @token.invalidated? 
       if request.post?
         any_auth = false
         @token.client_application.permissions.each do |pref|