Skip to content

groupware: refactoring using function templates

911f8ad
Select commit
Loading
Failed to load commit list.
Open

Groupware #1994

groupware: refactoring using function templates
911f8ad
Select commit
Loading
Failed to load commit list.
SonarQubeCloud / SonarCloud Code Analysis failed Apr 20, 2026 in 1m 14s

Quality Gate failed

Failed conditions
9 Security Hotspots
3.6% Duplication on New Code (required ≤ 3%)
C Reliability Rating on New Code (required ≥ A)
E Security Rating on New Code (required ≥ A)

See analysis details on SonarQube Cloud

Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE

Annotations

Check failure on line 282 in tests/groupware/setup.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this method to reduce its Cognitive Complexity from 25 to the 15 allowed.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScDFiFdIOO1S-slO&open=AZwzScDFiFdIOO1S-slO&pullRequest=1994

Check warning on line 358 in pkg/jmap/tools.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Group together these consecutive parameters of the same type.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScF_iFdIOO1S-snn&open=AZwzScF_iFdIOO1S-snn&pullRequest=1994

Check warning on line 1464 in services/groupware/pkg/groupware/api_emails.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Complete the task associated to this TODO comment.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScA5iFdIOO1S-sj2&open=AZwzScA5iFdIOO1S-sj2&pullRequest=1994

Check warning on line 40 in pkg/jmap/api_contact.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Group together these consecutive parameters of the same type.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZ0rGN3pxZcaYPBBpiSU&open=AZ0rGN3pxZcaYPBBpiSU&pullRequest=1994

Check warning on line 87 in pkg/jmap/api_calendar.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Group together these consecutive parameters of the same type.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZ1Tf73RNywzTGnSfp96&open=AZ1Tf73RNywzTGnSfp96&pullRequest=1994

Check warning on line 296 in services/groupware/pkg/groupware/framework.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Complete the task associated to this TODO comment.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScBgiFdIOO1S-ski&open=AZwzScBgiFdIOO1S-ski&pullRequest=1994

Check warning on line 17 in services/groupware/pkg/groupware/dns.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Complete the task associated to this TODO comment.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScBUiFdIOO1S-skN&open=AZwzScBUiFdIOO1S-skN&pullRequest=1994

Check warning on line 913 in pkg/jmap/api_email.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Complete the task associated to this TODO comment.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScDfiFdIOO1S-slf&open=AZwzScDfiFdIOO1S-slf&pullRequest=1994

Check warning on line 208 in tests/groupware/groupware.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Prefer using an optional chain expression instead, as it's more concise and easier to read.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZyfW11CnmZyYEEPc9li&open=AZyfW11CnmZyYEEPc9li&pullRequest=1994

Check warning on line 194 in services/groupware/pkg/groupware/framework.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Complete the task associated to this TODO comment.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScBgiFdIOO1S-skX&open=AZwzScBgiFdIOO1S-skX&pullRequest=1994

Check warning on line 1754 in pkg/jmap/model.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Rename this interface to follow Go naming conventions for single-method interfaces.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScFfiFdIOO1S-snO&open=AZwzScFfiFdIOO1S-snO&pullRequest=1994

Check failure on line 272 in tests/groupware/setup.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Define a constant instead of duplicating this literal "the Stalwart API response is not 200 but %v %v" 3 times.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScDFiFdIOO1S-slD&open=AZwzScDFiFdIOO1S-slD&pullRequest=1994

Check failure on line 185 in services/groupware/pkg/metrics/metrics.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Define a constant instead of duplicating this literal "Number of JMAP requests" 3 times.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScCRiFdIOO1S-slA&open=AZwzScCRiFdIOO1S-slA&pullRequest=1994

Check warning on line 29 in pkg/jmap/client.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Rename this interface to follow Go naming conventions for single-method interfaces.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZ1zG6Zs87T5dO55V85S&open=AZ1zG6Zs87T5dO55V85S&pullRequest=1994

Check warning on line 1 in vendor/github.com/gogs/chardet/icu-license.html

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Add "lang" and/or "xml:lang" attributes to this "<html>" element

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScH9iFdIOO1S-soo&open=AZwzScH9iFdIOO1S-soo&pullRequest=1994

Check warning on line 1183 in services/groupware/pkg/groupware/api_emails.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Complete the task associated to this TODO comment.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScA5iFdIOO1S-sjz&open=AZwzScA5iFdIOO1S-sjz&pullRequest=1994

Check warning on line 501 in pkg/jmap/integration_test.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Group together these consecutive parameters of the same type.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScEIiFdIOO1S-sms&open=AZwzScEIiFdIOO1S-sms&pullRequest=1994

Check warning on line 240 in services/groupware/pkg/groupware/request.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Group together these consecutive parameters of the same type.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScB1iFdIOO1S-sk8&open=AZwzScB1iFdIOO1S-sk8&pullRequest=1994

Check warning on line 1237 in pkg/jmap/model.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Rename this interface to follow Go naming conventions for single-method interfaces.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZ1zG6aV87T5dO55V85Y&open=AZ1zG6aV87T5dO55V85Y&pullRequest=1994

Check failure on line 28 in services/groupware/pkg/middleware/auth.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this method to reduce its Cognitive Complexity from 33 to the 15 allowed.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScCAiFdIOO1S-sk-&open=AZwzScCAiFdIOO1S-sk-&pullRequest=1994

Check warning on line 206 in tests/groupware/groupware.ts

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Prefer using an optional chain expression instead, as it's more concise and easier to read.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZyfW11CnmZyYEEPc9lg&open=AZyfW11CnmZyYEEPc9lg&pullRequest=1994

Check warning on line 774 in pkg/jmap/api_email.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Complete the task associated to this TODO comment.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScDfiFdIOO1S-sld&open=AZwzScDfiFdIOO1S-sld&pullRequest=1994

Check warning on line 226 in services/groupware/pkg/groupware/framework.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Complete the task associated to this TODO comment.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScBgiFdIOO1S-skd&open=AZwzScBgiFdIOO1S-skd&pullRequest=1994

Check warning on line 1843 in pkg/jscontact/model.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Rename this interface to follow Go naming conventions for single-method interfaces.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScHKiFdIOO1S-soW&open=AZwzScHKiFdIOO1S-soW&pullRequest=1994

Check warning on line 1212 in services/groupware/pkg/groupware/api_emails.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Complete the task associated to this TODO comment.

See more on https://sonarcloud.io/project/issues?id=opencloud-eu_opencloud&issues=AZwzScA5iFdIOO1S-sj0&open=AZwzScA5iFdIOO1S-sj0&pullRequest=1994