From dc7bdfab893bdf44ad439e49b25ad3611191ad7a Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Thu, 26 Sep 2024 16:19:37 +0200 Subject: [PATCH] fix: provide fallback api version [LIBS-683] (#877) * fix: provide fallback api version [LIBS-683] * fix: update upload-artifiact for CI * fix: update download artifact --- .github/workflows/dhis2-verify-lib.yml | 6 +++--- adapter/src/components/ServerVersionProvider.js | 4 +++- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/dhis2-verify-lib.yml b/.github/workflows/dhis2-verify-lib.yml index e7f8a08b5..5cd4020e8 100644 --- a/.github/workflows/dhis2-verify-lib.yml +++ b/.github/workflows/dhis2-verify-lib.yml @@ -29,7 +29,7 @@ jobs: - name: Build run: yarn build - - uses: actions/upload-artifact@v2 + - uses: actions/upload-artifact@v4 with: name: lib-build path: | @@ -61,7 +61,7 @@ jobs: with: node-version: 14.x - - uses: actions/download-artifact@v2 + - uses: actions/download-artifact@v4 with: name: lib-build @@ -83,7 +83,7 @@ jobs: with: node-version: 14.x - - uses: actions/download-artifact@v2 + - uses: actions/download-artifact@v4 with: name: lib-build diff --git a/adapter/src/components/ServerVersionProvider.js b/adapter/src/components/ServerVersionProvider.js index 4429f4c54..e82290046 100644 --- a/adapter/src/components/ServerVersionProvider.js +++ b/adapter/src/components/ServerVersionProvider.js @@ -113,7 +113,9 @@ export const ServerVersionProvider = ({ setSystemInfoState({ loading: false, error: undefined, - systemInfo: { version: loginConfig.apiVersion }, + systemInfo: { + version: loginConfig.apiVersion ?? '2.41', + }, }) }) .catch((e) => {