We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3bb8d3e commit 282dde0Copy full SHA for 282dde0
1 file changed
src/auth.js
@@ -126,15 +126,18 @@ function registerOauth() {
126
})
127
}
128
129
+ let handled
130
if (req.hostname !== redirectURL.hostname) {
- await handleServiceUrl(req, res)
131
+ handled = await handleServiceUrl(req, res)
132
133
134
if (!req.isAuthenticated()) {
135
return res.redirect("/auth")
136
137
- next()
138
+ if (!handled) {
139
+ next()
140
+ }
141
142
143
router.get("/auth", passport.authenticate("oauth2"))
@@ -163,9 +166,11 @@ function registerFakeAuth() {
163
166
164
167
165
168
169
+ const handled = await handleServiceUrl(req, res)
170
171
172
173
174
175
176
router.get("/auth", (req, res) => {
0 commit comments