likyh commented on code in PR #4359:
URL:
https://github.com/apache/incubator-devlake/pull/4359#discussion_r1102217341
##########
backend/plugins/gitlab/tasks/mr_extractor.go:
##########
@@ -80,23 +82,36 @@ func ExtractApiMergeRequests(taskCtx plugin.SubTaskContext)
errors.Error {
var labelTypeRegex *regexp.Regexp
var labelComponentRegex *regexp.Regexp
var prType = config.PrType
- var err error
+
+ var err1 error
if len(prType) > 0 {
- labelTypeRegex, err = regexp.Compile(prType)
- if err != nil {
- return errors.Default.Wrap(err, "regexp Compile prType
failed")
+ labelTypeRegex, err1 = regexp.Compile(prType)
+ if err1 != nil {
+ return errors.Default.Wrap(err1, "regexp Compile prType
failed")
}
}
var prComponent = config.PrComponent
if len(prComponent) > 0 {
- labelComponentRegex, err = regexp.Compile(prComponent)
- if err != nil {
- return errors.Default.Wrap(err, "regexp Compile
prComponent failed")
+ labelComponentRegex, err1 = regexp.Compile(prComponent)
+ if err1 != nil {
+ return errors.Default.Wrap(err1, "regexp Compile
prComponent failed")
}
}
+ needDetail := false
+
extractor, err := api.NewApiExtractor(api.ApiExtractorArgs{
RawDataSubTaskArgs: *rawDataSubTaskArgs,
Extract: func(row *api.RawData) ([]interface{}, errors.Error) {
Review Comment:
typo: row-> raw
--
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]