SHARE
TWEET

Untitled

a guest Aug 19th, 2019 76 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. pipeline :api do
  2.   plug :accepts, ["json"]
  3.   plug :fetch_session
  4.   plug BlogApi.Plugs.SetUser
  5. end
  6.  
  7. scope "/api", BlogApiWeb do
  8.   pipe_through :api
  9.  
  10.   get "/posts", PostController, :index
  11.  
  12.   resources "/users", UserController, param: "uuid" do
  13.     resources "/posts", PostController, except: [:index, :new, :edit], param: "uuid"
  14.   end
  15. end
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top