File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed
Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -36,14 +36,16 @@ export class AntigravityExecutor extends BaseExecutor {
3636 }
3737
3838 transformRequest ( model , body , stream , credentials ) {
39- const hasRealProject = ! ! credentials ?. projectId ;
40- const projectId = credentials ?. projectId || this . generateProjectId ( ) ;
39+ const bodyProjectId = body ?. project ;
40+ const credentialsProjectId = credentials ?. projectId ;
41+ const hasExplicitProject = ! ! ( bodyProjectId || credentialsProjectId ) ;
42+ const projectId = bodyProjectId || credentialsProjectId || this . generateProjectId ( ) ;
4143
42- if ( ! hasRealProject ) {
44+ if ( ! hasExplicitProject ) {
4345 console . warn (
44- `[Antigravity] ⚠️ No projectId in credentials — using generated fallback "${ projectId } ". ` +
46+ `[Antigravity] ⚠️ No projectId provided via body or credentials — using generated fallback "${ projectId } ". ` +
4547 `This may cause 404 errors if the account has no active GCP project. ` +
46- `Ensure the OAuth token includes a valid project.`
48+ `Ensure the OAuth token includes a valid project or the request includes a project field .`
4749 ) ;
4850 }
4951
You can’t perform that action at this time.
0 commit comments