This is an automated email from the ASF dual-hosted git repository.

winterhazel pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/cloudstack.git


The following commit(s) were added to refs/heads/main by this push:
     new 8148c532e06 Ignore projectid=-1 on Quota summary (#13658)
8148c532e06 is described below

commit 8148c532e06f72116a19e94aaa51fcca7eb135b6
Author: Fabricio Duarte <[email protected]>
AuthorDate: Wed Jul 22 12:09:21 2026 -0300

    Ignore projectid=-1 on Quota summary (#13658)
---
 .../java/org/apache/cloudstack/api/command/QuotaSummaryCmd.java   | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git 
a/plugins/database/quota/src/main/java/org/apache/cloudstack/api/command/QuotaSummaryCmd.java
 
b/plugins/database/quota/src/main/java/org/apache/cloudstack/api/command/QuotaSummaryCmd.java
index 870b9b6df6e..89ab96ebb9f 100644
--- 
a/plugins/database/quota/src/main/java/org/apache/cloudstack/api/command/QuotaSummaryCmd.java
+++ 
b/plugins/database/quota/src/main/java/org/apache/cloudstack/api/command/QuotaSummaryCmd.java
@@ -116,6 +116,9 @@ public class QuotaSummaryCmd extends BaseListCmd {
     }
 
     public Long getProjectId() {
+        if (projectId == null || projectId == -1L) {
+            return null;
+        }
         return projectId;
     }
 
@@ -129,9 +132,10 @@ public class QuotaSummaryCmd extends BaseListCmd {
 
     @Override
     public long getEntityOwnerId() {
-        if (ObjectUtils.allNull(accountId, accountName, projectId)) {
+        Long convertedProjectId = getProjectId();
+        if (ObjectUtils.allNull(accountId, accountName, convertedProjectId)) {
             return -1;
         }
-        return _accountService.finalizeAccountId(accountId, accountName, 
domainId, projectId);
+        return _accountService.finalizeAccountId(accountId, accountName, 
domainId, convertedProjectId);
     }
 }

Reply via email to