You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@devlake.apache.org by ab...@apache.org on 2022/08/18 08:18:39 UTC

[incubator-devlake] branch main updated (75fe05f5 -> 8007ff2a)

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

abeizn pushed a change to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git


    from 75fe05f5 fix: fix Jira adding connection bug
     new e616c24f perf: added the error handling
     new 78382ff5 perf: added the error handling
     new 9548059c perf: added the error handling
     new ba954375 perf: added the error handling
     new 532e9f84 perf: edited err to nil
     new e375da29 perf: added nil for error handling
     new 8007ff2a added error handling

The 7 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 plugins/github/api/connection.go  | 4 ++--
 plugins/gitlab/api/connection.go  | 3 +++
 plugins/jenkins/api/connection.go | 3 +++
 plugins/jira/api/connection.go    | 3 +++
 plugins/tapd/api/connection.go    | 5 ++++-
 5 files changed, 15 insertions(+), 3 deletions(-)


[incubator-devlake] 01/07: perf: added the error handling

Posted by ab...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

abeizn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git

commit e616c24f8383b4f14d841fce3e5d2d82c96754d5
Author: PRANSHU RAJ <50...@users.noreply.github.com>
AuthorDate: Thu Jul 21 11:05:46 2022 +0530

    perf: added the error handling
    
    Added the error handling in GetConnection
---
 plugins/gitlab/api/connection.go | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/plugins/gitlab/api/connection.go b/plugins/gitlab/api/connection.go
index e60417fa..22b1a539 100644
--- a/plugins/gitlab/api/connection.go
+++ b/plugins/gitlab/api/connection.go
@@ -159,6 +159,9 @@ func ListConnections(input *core.ApiResourceInput) (*core.ApiResourceOutput, err
 func GetConnection(input *core.ApiResourceInput) (*core.ApiResourceOutput, error) {
 	connection := &models.GitlabConnection{}
 	err := connectionHelper.First(connection, input.Params)
+	if err != nil {
+		return nil, err
+	}
 	return &core.ApiResourceOutput{Body: connection}, err
 }
 


[incubator-devlake] 06/07: perf: added nil for error handling

Posted by ab...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

abeizn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git

commit e375da291b1d54f193011f172f62a53430954090
Author: PRANSHU RAJ <50...@users.noreply.github.com>
AuthorDate: Fri Jul 22 16:55:49 2022 +0530

    perf: added nil for error handling
    
    changed err to nil
---
 plugins/tapd/api/connection.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/plugins/tapd/api/connection.go b/plugins/tapd/api/connection.go
index 415df7cb..1120ddbb 100644
--- a/plugins/tapd/api/connection.go
+++ b/plugins/tapd/api/connection.go
@@ -167,5 +167,5 @@ func GetConnection(input *core.ApiResourceInput) (*core.ApiResourceOutput, error
 	if err != nil {
 		return nil,err
 	}
-	return &core.ApiResourceOutput{Body: connection}, nil
+	return &core.ApiResourceOutput{Body: connection},nil
 }


[incubator-devlake] 04/07: perf: added the error handling

Posted by ab...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

abeizn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git

commit ba954375910d199809641d0ea80ab60b77fad4ad
Author: PRANSHU RAJ <50...@users.noreply.github.com>
AuthorDate: Thu Jul 21 11:10:50 2022 +0530

    perf: added the error handling
    
    added the error handling GetConnection
---
 plugins/tapd/api/connection.go | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/plugins/tapd/api/connection.go b/plugins/tapd/api/connection.go
index 4b1f3609..b582bed7 100644
--- a/plugins/tapd/api/connection.go
+++ b/plugins/tapd/api/connection.go
@@ -164,5 +164,8 @@ func ListConnections(input *core.ApiResourceInput) (*core.ApiResourceOutput, err
 func GetConnection(input *core.ApiResourceInput) (*core.ApiResourceOutput, error) {
 	connection := &models.TapdConnection{}
 	err := connectionHelper.First(connection, input.Params)
+	if err != nil {
+		return nil, err
+	}
 	return &core.ApiResourceOutput{Body: connection}, err
 }


[incubator-devlake] 05/07: perf: edited err to nil

Posted by ab...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

abeizn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git

commit 532e9f84c79007c5ed30d73fceb7bcb7266f52b7
Author: PRANSHU RAJ <50...@users.noreply.github.com>
AuthorDate: Fri Jul 22 16:05:01 2022 +0530

    perf: edited err to nil
    
    edited the err handling err to nil
---
 plugins/tapd/api/connection.go | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/plugins/tapd/api/connection.go b/plugins/tapd/api/connection.go
index b582bed7..415df7cb 100644
--- a/plugins/tapd/api/connection.go
+++ b/plugins/tapd/api/connection.go
@@ -165,7 +165,7 @@ func GetConnection(input *core.ApiResourceInput) (*core.ApiResourceOutput, error
 	connection := &models.TapdConnection{}
 	err := connectionHelper.First(connection, input.Params)
 	if err != nil {
-		return nil, err
+		return nil,err
 	}
-	return &core.ApiResourceOutput{Body: connection}, err
+	return &core.ApiResourceOutput{Body: connection}, nil
 }


[incubator-devlake] 02/07: perf: added the error handling

Posted by ab...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

abeizn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git

commit 78382ff5cb1f559e25643562c500c9cee3dbf485
Author: PRANSHU RAJ <50...@users.noreply.github.com>
AuthorDate: Thu Jul 21 11:07:53 2022 +0530

    perf: added the error handling
    
    added the error handling in GetConnection
---
 plugins/jenkins/api/connection.go | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/plugins/jenkins/api/connection.go b/plugins/jenkins/api/connection.go
index edd72385..be180c2e 100644
--- a/plugins/jenkins/api/connection.go
+++ b/plugins/jenkins/api/connection.go
@@ -161,6 +161,9 @@ func ListConnections(input *core.ApiResourceInput) (*core.ApiResourceOutput, err
 func GetConnection(input *core.ApiResourceInput) (*core.ApiResourceOutput, error) {
 	connection := &models.JenkinsConnection{}
 	err := connectionHelper.First(connection, input.Params)
+	if err != nil {
+		return nil, err
+	}
 	return &core.ApiResourceOutput{Body: connection}, err
 }
 


[incubator-devlake] 03/07: perf: added the error handling

Posted by ab...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

abeizn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git

commit 9548059c14bda1c18f1ee3298d0d05f82f41660a
Author: PRANSHU RAJ <50...@users.noreply.github.com>
AuthorDate: Thu Jul 21 11:09:41 2022 +0530

    perf: added the error handling
    
    added the error handling GetConnection
---
 plugins/jira/api/connection.go | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/plugins/jira/api/connection.go b/plugins/jira/api/connection.go
index 1cc95c80..1c071504 100644
--- a/plugins/jira/api/connection.go
+++ b/plugins/jira/api/connection.go
@@ -210,5 +210,8 @@ func ListConnections(input *core.ApiResourceInput) (*core.ApiResourceOutput, err
 func GetConnection(input *core.ApiResourceInput) (*core.ApiResourceOutput, error) {
 	connection := &models.JiraConnection{}
 	err := connectionHelper.First(connection, input.Params)
+	if err != nil {
+		return nil, err
+	}
 	return &core.ApiResourceOutput{Body: connection}, err
 }


[incubator-devlake] 07/07: added error handling

Posted by ab...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

abeizn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git

commit 8007ff2a67f5773aa09b96cf020131746c137240
Author: PRANSHU RAJ <50...@users.noreply.github.com>
AuthorDate: Thu Aug 4 02:04:33 2022 +0530

    added error handling
---
 plugins/github/api/connection.go | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/plugins/github/api/connection.go b/plugins/github/api/connection.go
index e7e4bf6c..3cff808c 100644
--- a/plugins/github/api/connection.go
+++ b/plugins/github/api/connection.go
@@ -173,7 +173,7 @@ func DeleteConnection(input *core.ApiResourceInput) (*core.ApiResourceOutput, er
 		return nil, err
 	}
 	err = connectionHelper.Delete(connection)
-	return &core.ApiResourceOutput{Body: connection}, err
+	return &core.ApiResourceOutput{Body: connection}, nil
 }
 
 // @Summary get all github connections
@@ -206,5 +206,5 @@ func GetConnection(input *core.ApiResourceInput) (*core.ApiResourceOutput, error
 	if err != nil {
 		return nil, err
 	}
-	return &core.ApiResourceOutput{Body: connection}, err
+	return &core.ApiResourceOutput{Body: connection}, nil
 }