You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by GitBox <gi...@apache.org> on 2022/09/11 15:57:50 UTC

[GitHub] [dolphinscheduler] github-code-scanning[bot] commented on a diff in pull request #11670: [Feature-11473][Task]Support test task

github-code-scanning[bot] commented on code in PR #11670:
URL: https://github.com/apache/dolphinscheduler/pull/11670#discussion_r967850742


##########
dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/DataSourceServiceImpl.java:
##########
@@ -138,6 +138,10 @@
         dataSource.setConnectionParams(JSONUtils.toJsonString(connectionParam));
         dataSource.setCreateTime(now);
         dataSource.setUpdateTime(now);
+        if (!String.valueOf(datasourceParam.getTestFlag()).equals("")) {

Review Comment:
   ## Inefficient empty string test
   
   Inefficient comparison to empty string, check for zero length instead.
   
   [Show more details](https://github.com/apache/dolphinscheduler/security/code-scanning/1202)



-- 
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: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org