Skip to content

Commit 7e0be69

Browse files
committed
Omit unneeded warning if no gitlab is configured
This patch should fix the unneeded warning of the wrong API version, when gitlab isn't configured at all. Signed-off-by: Sheogorath <[email protected]>
1 parent 9e4d165 commit 7e0be69

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/config/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ config.isOAuth2Enable = config.oauth2.clientID && config.oauth2.clientSecret
104104
config.isPDFExportEnable = config.allowPDFExport
105105

106106
// Check gitlab api version
107-
if (config.gitlab.version !== 'v4' && config.gitlab.version !== 'v3') {
107+
if (config.gitlab && config.gitlab.version !== 'v4' && config.gitlab.version !== 'v3') {
108108
logger.warn('config.js contains wrong version (' + config.gitlab.version + ') for gitlab api; it should be \'v3\' or \'v4\'. Defaulting to v4')
109109
config.gitlab.version = 'v4'
110110
}

0 commit comments

Comments
 (0)