Permalink
Browse files

formatting

  • Loading branch information...
1 parent f56cea8 commit 1307a77e6fe9cac8ea2e83cdd909fbdf5b4d89cc @maccman committed Mar 22, 2010
Showing with 10 additions and 10 deletions.
  1. +10 −10 README.markdown
View
@@ -32,17 +32,17 @@ paid version, 7,400,000 emails per day.
* Configure the callback URL in your Remail App Engine.
* Create a email controller, that looks a bit like this (remember to configure the routes):
- class EmailsController < ApplicationController
- skip_before_filter :verify_authenticity_token
-
- def create
- if request.headers["Authorization"] != your_api_key
- return head(:unauthorized)
+ class EmailsController < ApplicationController
+ skip_before_filter :verify_authenticity_token
+
+ def create
+ if request.headers["Authorization"] != your_api_key
+ return head(:unauthorized)
+ end
+ UserMailer.receive(params[:email][:raw])
+ head :success
+ end
end
- UserMailer.receive(params[:email][:raw])
- head :success
- end
- end
The API key is also passed through as an Authorization header,
you should definitely validate that.

0 comments on commit 1307a77

Please sign in to comment.