Skip to content

fix(web): OAuth quota size #18526

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

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

wuzihao051119
Copy link
Contributor

Fixes #18504.

Copy link
Member

@danieldietzler danieldietzler left a comment

Choose a reason for hiding this comment

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

I think it's more reasonable to just drop the default quota field. If the claim isn't provided it's unlimited, otherwise it's whatever the claim is.

@wuzihao051119 wuzihao051119 force-pushed the fix-oauth-quota-size branch from d9f8695 to ac9af24 Compare May 23, 2025 13:56
@wuzihao051119 wuzihao051119 force-pushed the fix-oauth-quota-size branch from ac9af24 to 3b88e3a Compare May 23, 2025 15:27
@github-actions github-actions bot added the documentation Improvements or additions to documentation label May 23, 2025
Copy link
Contributor

github-actions bot commented May 23, 2025

📖 Documentation deployed to pr-18526.preview.immich.app

@wuzihao051119 wuzihao051119 force-pushed the fix-oauth-quota-size branch from e3f7d2d to 0890d01 Compare May 23, 2025 15:57
@wuzihao051119
Copy link
Contributor Author

Done.

@@ -207,7 +207,7 @@
"oauth_storage_quota_claim": "Storage quota claim",
"oauth_storage_quota_claim_description": "Automatically set the user's storage quota to the value of this claim.",
"oauth_storage_quota_default": "Default storage quota (GiB)",
"oauth_storage_quota_default_description": "Quota in GiB to be used when no claim is provided (Enter 0 for unlimited quota).",
"oauth_storage_quota_default_description": "Quota in GiB to be used when no claim is provided.",
Copy link
Member

Choose a reason for hiding this comment

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

You should create a new key for this, since otherwise this won't show up as "untranslated" in other languages.

@@ -253,7 +253,7 @@ export const defaults = Object.freeze<SystemConfig>({
buttonText: 'Login with OAuth',
clientId: '',
clientSecret: '',
defaultStorageQuota: 0,
defaultStorageQuota: undefined,
Copy link
Member

Choose a reason for hiding this comment

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

Semantically I would probably prefer null here instead of undefined, since from my perspective we explicitly want to say "should be unlimited" and not "we don't define the value because we don't care about it". Would be interested to hear @jrasm91 thoughts on this though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

OAuth: DEFAULT STORAGE QUOTA does not permit 0GB accounts
2 participants