-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/room ownership #833
Conversation
brianpeiris
commented
Jan 11, 2019
- Adds a sign-in/out link to the home page
- Adds auth tokens to room creation and room join
src/hub.js
Outdated
@@ -531,6 +531,10 @@ document.addEventListener("DOMContentLoaded", async () => { | |||
|
|||
const pushSubscriptionEndpoint = await subscriptions.getCurrentEndpoint(); | |||
const joinPayload = { profile: store.state.profile, push_subscription_endpoint: pushSubscriptionEndpoint, context }; | |||
const { token } = store.state.credentials; | |||
if (token) { | |||
joinPayload.token = token; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
notes from other PR, but these should prob be auth_token
vs perm_token
@@ -41,12 +45,18 @@ class HomeRoot extends Component { | |||
state = { | |||
environments: [], | |||
dialog: null, | |||
signedIn: null, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit, maybe make this authenticated
or signedIn
everywhere, not both
document.location = `/hub.html?hub_id=${hub.hub_id}`; | ||
} | ||
createRoom = () => { | ||
createAndRedirectToNewHub(this.state.customRoomName, this.props.sceneId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oops
LGTM mod the changes to move away from Also, nice to see the auth channel stuff migrated over to the home page nicely. 😅 |
|
Merging in #843 |