fix(nbstore): update workspace blob quota query (#12191)

Change the query for querying quota of Cloud Blob Storage.

The original query used new fields, which caused errors in the old version of the server. This PR uses a simpler query to ensure compatibility.

<!-- This is an auto-generated comment: release notes by coderabbit.ai -->

## Summary by CodeRabbit

- **New Features**
  - Added the ability to retrieve a workspace's blob storage quota, including both the raw limit and a human-readable format, via a new query.

- **Bug Fixes**
  - Updated quota retrieval to use the new blob-specific quota query for improved accuracy.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
EYHN
2025-05-08 09:14:54 +00:00
parent 86742c1307
commit 52253e9e82
4 changed files with 51 additions and 2 deletions
@@ -4,7 +4,7 @@ import {
listBlobsQuery,
releaseDeletedBlobsMutation,
setBlobMutation,
workspaceQuotaQuery,
workspaceBlobQuotaQuery,
} from '@affine/graphql';
import {
@@ -161,7 +161,7 @@ export class CloudBlobStorage extends BlobStorageBase {
}
try {
const res = await this.connection.gql({
query: workspaceQuotaQuery,
query: workspaceBlobQuotaQuery,
variables: { id: this.options.id },
});