diff options
author | Christoph (Sheogorath) Kern | 2018-07-31 10:55:08 +0200 |
---|---|---|
committer | GitHub | 2018-07-31 10:55:08 +0200 |
commit | 881ca88c517ab1c212196e43bd6bc865ba7a8254 (patch) | |
tree | 9c8d2a7882b80653a724272aea1bc5bc956ef888 /lib/config/index.js | |
parent | 48ddcef31c4c13557e1bd2fbc128e82e0e2df5d8 (diff) | |
parent | 66d374b1289e6dd33008dc931e9fb642051724d0 (diff) |
Merge pull request #908 from micedre/gitlabV4
Add possibility to choose between version v3 or v4 for the gitlab api.
Diffstat (limited to '')
-rw-r--r-- | lib/config/index.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/config/index.js b/lib/config/index.js index ac03fcd4..e66c513d 100644 --- a/lib/config/index.js +++ b/lib/config/index.js @@ -103,6 +103,12 @@ config.isSAMLEnable = config.saml.idpSsoUrl config.isOAuth2Enable = config.oauth2.clientID && config.oauth2.clientSecret config.isPDFExportEnable = config.allowPDFExport +// Check gitlab api version +if (config.gitlab.version !== 'v4' || config.gitlab.version !== 'v3') { + logger.warn('config.js contains wrong version (' + config.gitlab.version + ') for gitlab api; it should be \'v3\' or \'v4\'. Defaulting to v3') + config.gitlab.version = 'v4' +} + // Only update i18n files in development setups config.updateI18nFiles = (env === Environment.development) |