Unverified Commit 8c7899c3 authored by Filipe de Lima Brito's avatar Filipe de Lima Brito Committed by GitHub

Merge pull request #1469 from RocketChat/fix/oauth-path

[FIX] Custom OAuth url
parents 3f2148d1 57c042ab
......@@ -113,12 +113,18 @@ object OauthHelper {
state: String,
scope: String
): String {
return host +
authorizePath +
(authorizePath +
"?client_id=$clientId" +
"&redirect_uri=${serverUrl.removeTrailingSlash()}/_oauth/$serviceName" +
"&state=$state" +
"&scope=$scope" +
"&response_type=code"
).let {
return if (it.contains(host)) {
it
} else {
host + it
}
}
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment