chore(redirectTo-flag): removed redirectTo featureFlag (#18355)
parent
1bfd6d0827
commit
22e135c06a
|
@ -6,6 +6,7 @@
|
||||||
1. [18322](https://github.com/influxdata/influxdb/pull/18322): Add ability to export a stack's existing (as they are in the platform) resource state as a pkg
|
1. [18322](https://github.com/influxdata/influxdb/pull/18322): Add ability to export a stack's existing (as they are in the platform) resource state as a pkg
|
||||||
1. [18334](https://github.com/influxdata/influxdb/pull/18334): Update influx pkg commands with improved usage and examples in long form.
|
1. [18334](https://github.com/influxdata/influxdb/pull/18334): Update influx pkg commands with improved usage and examples in long form.
|
||||||
1. [18344](https://github.com/influxdata/influxdb/pull/18344): Extend influx CLI with version and User-Agent.
|
1. [18344](https://github.com/influxdata/influxdb/pull/18344): Extend influx CLI with version and User-Agent.
|
||||||
|
1. [18355](https://github.com/influxdata/influxdb/pull/18355): Integrate RedirectTo functionality so CLOUD users now get navigated back to the originally linked page after login
|
||||||
|
|
||||||
### Bug Fixes
|
### Bug Fixes
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,6 @@ import {client} from 'src/utils/api'
|
||||||
// Components
|
// Components
|
||||||
import {ErrorHandling} from 'src/shared/decorators/errors'
|
import {ErrorHandling} from 'src/shared/decorators/errors'
|
||||||
import {SpinnerContainer, TechnoSpinner} from '@influxdata/clockface'
|
import {SpinnerContainer, TechnoSpinner} from '@influxdata/clockface'
|
||||||
import {isFlagEnabled} from 'src/shared/utils/featureFlag'
|
|
||||||
|
|
||||||
// Utils
|
// Utils
|
||||||
import {
|
import {
|
||||||
|
@ -93,7 +92,7 @@ export class Signin extends PureComponent<Props, State> {
|
||||||
|
|
||||||
clearInterval(this.intervalID)
|
clearInterval(this.intervalID)
|
||||||
|
|
||||||
if (CLOUD && isFlagEnabled('redirectToCloud')) {
|
if (CLOUD) {
|
||||||
const url = new URL(
|
const url = new URL(
|
||||||
`${window.location.origin}${CLOUD_SIGNIN_PATHNAME}?redirectTo=${
|
`${window.location.origin}${CLOUD_SIGNIN_PATHNAME}?redirectTo=${
|
||||||
window.location.href
|
window.location.href
|
||||||
|
@ -104,12 +103,6 @@ export class Signin extends PureComponent<Props, State> {
|
||||||
throw error
|
throw error
|
||||||
}
|
}
|
||||||
|
|
||||||
if (CLOUD) {
|
|
||||||
// TODO: add returnTo to CLOUD signin
|
|
||||||
window.location.pathname = CLOUD_SIGNIN_PATHNAME
|
|
||||||
throw error
|
|
||||||
}
|
|
||||||
|
|
||||||
if (pathname.startsWith('/signin')) {
|
if (pathname.startsWith('/signin')) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,7 +22,6 @@ import auth0js, {WebAuth} from 'auth0-js'
|
||||||
import {LoginForm} from 'src/onboarding/components/LoginForm'
|
import {LoginForm} from 'src/onboarding/components/LoginForm'
|
||||||
import {SocialButton} from 'src/shared/components/SocialButton'
|
import {SocialButton} from 'src/shared/components/SocialButton'
|
||||||
import {GoogleLogo} from 'src/clientLibraries/graphics'
|
import {GoogleLogo} from 'src/clientLibraries/graphics'
|
||||||
import {isFlagEnabled} from 'src/shared/utils/featureFlag'
|
|
||||||
|
|
||||||
// Types
|
// Types
|
||||||
import {Auth0Connection, FormFieldValidation} from 'src/types'
|
import {Auth0Connection, FormFieldValidation} from 'src/types'
|
||||||
|
@ -63,13 +62,8 @@ class LoginPageContents extends PureComponent<DispatchProps> {
|
||||||
|
|
||||||
public async componentDidMount() {
|
public async componentDidMount() {
|
||||||
try {
|
try {
|
||||||
let config
|
const redirectTo = getFromLocalStorage('redirectTo') || '/'
|
||||||
if (isFlagEnabled('redirectToCloud')) {
|
const config = await getAuth0Config(redirectTo)
|
||||||
const redirectTo = getFromLocalStorage('redirectTo') || '/'
|
|
||||||
config = await getAuth0Config(redirectTo)
|
|
||||||
} else {
|
|
||||||
config = await getAuth0Config()
|
|
||||||
}
|
|
||||||
this.auth0 = new auth0js.WebAuth({
|
this.auth0 = new auth0js.WebAuth({
|
||||||
domain: config.domain,
|
domain: config.domain,
|
||||||
clientID: config.clientID,
|
clientID: config.clientID,
|
||||||
|
@ -79,10 +73,6 @@ class LoginPageContents extends PureComponent<DispatchProps> {
|
||||||
})
|
})
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error(error)
|
console.error(error)
|
||||||
// TODO: uncomment after demo day
|
|
||||||
// redirect to universal login page if there's an error
|
|
||||||
// window.location.href =
|
|
||||||
// 'https://auth.a.influxcloud.net/'
|
|
||||||
throw error
|
throw error
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,7 +11,6 @@ export const OSS_FLAGS = {
|
||||||
fluxParser: false,
|
fluxParser: false,
|
||||||
matchingNotificationRules: false,
|
matchingNotificationRules: false,
|
||||||
notebooks: false,
|
notebooks: false,
|
||||||
redirectToCloud: false,
|
|
||||||
telegrafEditor: false,
|
telegrafEditor: false,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,7 +24,6 @@ export const CLOUD_FLAGS = {
|
||||||
fluxParser: false,
|
fluxParser: false,
|
||||||
matchingNotificationRules: false,
|
matchingNotificationRules: false,
|
||||||
notebooks: false,
|
notebooks: false,
|
||||||
redirectToCloud: false,
|
|
||||||
telegrafEditor: false,
|
telegrafEditor: false,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue