You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a full rewrite of the library, and are several breaking changes. You're encouraged to test your app well if you upgrade from 0.4.x.
6
+
7
+
### 1. ExOauth2Provider
8
+
9
+
Read the [ExOauth2Provider CHANGELOG.md](https://github.com/danschultzer/ex_oauth2_provider) for upgrade instructions.
10
+
11
+
### 2. Routes
12
+
13
+
Routes are now separated into api and non api routes. Update your routes like so:
14
+
15
+
```elixir
16
+
defmoduleMyAppWeb.Routerdo
17
+
useMyAppWeb, :router
18
+
usePhoenixOauth2Provider.Router
19
+
20
+
# ...
21
+
22
+
pipeline :protecteddo
23
+
# Require user authentication
24
+
end
25
+
26
+
scope "/"do
27
+
pipe_through :api
28
+
29
+
oauth_api_routes()
30
+
end
31
+
32
+
scope "/"do
33
+
pipe_through [:browser, :protected]
34
+
35
+
oauth_routes()
36
+
end
37
+
38
+
# ...
39
+
end
40
+
```
41
+
42
+
### 3. Templates and views
43
+
44
+
Update `:module` to `:web_module` in your configuration. Templates and views are no longer required to be generated so you can remove them entirely if the default ones work for you.
0 commit comments