Remove v0 version namespacing for API

This commit is contained in:
Thibault Jouan
2012-03-18 23:16:43 +00:00
parent 5dfafdcc46
commit 10a8e1f094
10 changed files with 11 additions and 13 deletions

View File

@@ -0,0 +1,14 @@
class Api::SessionsController < Api::ApplicationController
skip_before_filter :authenticate!, :only => [:create]
def create
user = User.find_by_email(params[:session][:email])
if ! user.try(:authenticate?, params[:session][:password])
return render :json => '', :status => :not_found
end
@user = user
self.current_user = @user
end
end