zhuangchong commented on a change in pull request #5895:
URL: https://github.com/apache/dolphinscheduler/pull/5895#discussion_r678759272



##########
File path: 
dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/SchedulerServiceImpl.java
##########
@@ -415,15 +416,18 @@
      * @return schedule list page
      */
     @Override
-    public Map<String, Object> querySchedule(User loginUser, String 
projectName, Integer processDefineId, String searchVal, Integer pageNo, Integer 
pageSize) {
+    public Result querySchedule(User loginUser, String projectName, Integer 
processDefineId, String searchVal, Integer pageNo, Integer pageSize) {
 
-        HashMap<String, Object> result = new HashMap<>();
+        Result result = new Result();
 
         Project project = projectMapper.queryByName(projectName);
 
+        Map<String, Object> checkResult = new HashMap<>();
         // check project auth
-        boolean hasProjectAndPerm = 
projectService.hasProjectAndPerm(loginUser, project, result);
+        boolean hasProjectAndPerm = 
projectService.hasProjectAndPerm(loginUser, project, checkResult);
         if (!hasProjectAndPerm) {
+            Status status = (Status) checkResult.get(Constants.STATUS);
+            putMsg(result,status);

Review comment:
       The exception information is not added to the Result.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to