Skip to content
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

Realm dropdown shows only readable realms #1041

Merged

Conversation

habdelra
Copy link
Contributor

@habdelra habdelra commented Feb 16, 2024

In this PR we make the base realm a read-only realm. The realm drop down is updated to only show writable realms. We also provide a default realm menu item fallbacks for the case when the current realm is a read-only realm.

TODO:

  • tests
  • update staging to make base realm read-only
  • update production to make base realm read-only

…down. provide realm dropdown default fallbacks
@@ -94,7 +94,7 @@ export class RealmAuthClient {
}

private async initiateSessionRequest() {
return fetch(`${this.realmURL.href}_session`, {
return this.loader.fetch(`${this.realmURL.href}_session`, {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this was necessary in order to perform resolution on the https://cardstack.com/base URL. in general we should always be using the loader's fetch.

@@ -106,7 +106,7 @@ export class RealmAuthClient {
}

private async challengeRequest(challenge: string) {
return fetch(`${this.realmURL.href}_session`, {
return this.loader.fetch(`${this.realmURL.href}_session`, {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto

Copy link

github-actions bot commented Feb 16, 2024

Test Results

518 tests  +10   514 ✔️ +10   7m 17s ⏱️ +34s
    1 suites ±  0       4 💤 ±  0 
    1 files   ±  0       0 ±  0 

Results for commit bb9bdac. ± Comparison against base commit 648d7ec.

♻️ This comment has been updated with latest results.

@habdelra habdelra marked this pull request as ready for review February 19, 2024 16:32
Copy link
Contributor

@jurgenwerk jurgenwerk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks OK to me!

@habdelra habdelra merged commit e3de0c2 into main Feb 20, 2024
18 checks passed
@delete-merged-branch delete-merged-branch bot deleted the cs-6381-code-mode-inspector-inherit-create-and-duplicate-instance branch February 20, 2024 18:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants