diff --git a/.github/workflows/PR-Demo-Comment-with-react.yml b/.github/workflows/PR-Demo-Comment-with-react.yml index 64cecea71..291e6b97a 100644 --- a/.github/workflows/PR-Demo-Comment-with-react.yml +++ b/.github/workflows/PR-Demo-Comment-with-react.yml @@ -48,7 +48,7 @@ jobs: # Generate GitHub App token - name: Generate GitHub App Token id: generate-token - uses: actions/create-github-app-token@3ff1caaa28b64c9cc276ce0a02e2ff584f3900c5 # v2.0.2 + uses: actions/create-github-app-token@db3cdf40984fe6fd25ae19ac2bf2f4886ae8d959 # v2.0.5 with: app-id: ${{ secrets.GH_APP_ID }} private-key: ${{ secrets.GH_APP_PRIVATE_KEY }} @@ -135,7 +135,7 @@ jobs: - name: Generate GitHub App Token id: generate-token - uses: actions/create-github-app-token@3ff1caaa28b64c9cc276ce0a02e2ff584f3900c5 # v2.0.2 + uses: actions/create-github-app-token@db3cdf40984fe6fd25ae19ac2bf2f4886ae8d959 # v2.0.5 with: app-id: ${{ secrets.GH_APP_ID }} private-key: ${{ secrets.GH_APP_PRIVATE_KEY }} diff --git a/.github/workflows/licenses-update.yml b/.github/workflows/licenses-update.yml index 0851b1490..e05c4b40f 100644 --- a/.github/workflows/licenses-update.yml +++ b/.github/workflows/licenses-update.yml @@ -24,7 +24,7 @@ jobs: - name: Generate GitHub App Token id: generate-token - uses: actions/create-github-app-token@3ff1caaa28b64c9cc276ce0a02e2ff584f3900c5 # v2.0.2 + uses: actions/create-github-app-token@db3cdf40984fe6fd25ae19ac2bf2f4886ae8d959 # v2.0.5 with: app-id: ${{ secrets.GH_APP_ID }} private-key: ${{ secrets.GH_APP_PRIVATE_KEY }} diff --git a/.github/workflows/pre_commit.yml b/.github/workflows/pre_commit.yml index 6e3bacd42..3c121da17 100644 --- a/.github/workflows/pre_commit.yml +++ b/.github/workflows/pre_commit.yml @@ -22,7 +22,7 @@ jobs: - name: Generate GitHub App Token id: generate-token - uses: actions/create-github-app-token@3ff1caaa28b64c9cc276ce0a02e2ff584f3900c5 # v2.0.2 + uses: actions/create-github-app-token@db3cdf40984fe6fd25ae19ac2bf2f4886ae8d959 # v2.0.5 with: app-id: ${{ secrets.GH_APP_ID }} private-key: ${{ secrets.GH_APP_PRIVATE_KEY }} diff --git a/.github/workflows/scorecards.yml b/.github/workflows/scorecards.yml index 327257e3f..3c2d59e3e 100644 --- a/.github/workflows/scorecards.yml +++ b/.github/workflows/scorecards.yml @@ -74,6 +74,6 @@ jobs: # Upload the results to GitHub's code scanning dashboard. - name: "Upload to code-scanning" - uses: github/codeql-action/upload-sarif@28deaeda66b76a05916b6923827895f2b14ab387 # v3.28.16 + uses: github/codeql-action/upload-sarif@60168efe1c415ce0f5521ea06d5c2062adbeed1b # v3.28.17 with: sarif_file: results.sarif diff --git a/.github/workflows/sync_files.yml b/.github/workflows/sync_files.yml index fdac87028..a9c72d5f0 100644 --- a/.github/workflows/sync_files.yml +++ b/.github/workflows/sync_files.yml @@ -30,7 +30,7 @@ jobs: - name: Generate GitHub App Token id: generate-token - uses: actions/create-github-app-token@3ff1caaa28b64c9cc276ce0a02e2ff584f3900c5 # v2.0.2 + uses: actions/create-github-app-token@db3cdf40984fe6fd25ae19ac2bf2f4886ae8d959 # v2.0.5 with: app-id: ${{ secrets.GH_APP_ID }} private-key: ${{ secrets.GH_APP_PRIVATE_KEY }} @@ -63,7 +63,7 @@ jobs: - name: Generate GitHub App Token id: generate-token - uses: actions/create-github-app-token@3ff1caaa28b64c9cc276ce0a02e2ff584f3900c5 # v2.0.2 + uses: actions/create-github-app-token@db3cdf40984fe6fd25ae19ac2bf2f4886ae8d959 # v2.0.5 with: app-id: ${{ vars.GH_APP_ID }} private-key: ${{ secrets.GH_APP_PRIVATE_KEY }} diff --git a/README.md b/README.md index d4be314e3..e642dd8b4 100644 --- a/README.md +++ b/README.md @@ -134,7 +134,7 @@ Stirling-PDF currently supports 39 languages! | Hungarian (Magyar) (hu_HU) |  | | Indonesian (Bahasa Indonesia) (id_ID) |  | | Irish (Gaeilge) (ga_IE) |  | -| Italian (Italiano) (it_IT) |  | +| Italian (Italiano) (it_IT) |  | | Japanese (日本語) (ja_JP) |  | | Korean (한국어) (ko_KR) |  | | Norwegian (Norsk) (no_NB) |  | diff --git a/build.gradle b/build.gradle index c872be274..1162952d9 100644 --- a/build.gradle +++ b/build.gradle @@ -19,7 +19,7 @@ import java.time.Year ext { springBootVersion = "3.4.5" - pdfboxVersion = "3.0.4" + pdfboxVersion = "3.0.5" imageioVersion = "3.12.0" lombokVersion = "1.18.38" bouncycastleVersion = "1.80" diff --git a/src/main/java/stirling/software/SPDF/config/security/database/DatabaseService.java b/src/main/java/stirling/software/SPDF/config/security/database/DatabaseService.java index 04b470f92..27e9ae7b1 100644 --- a/src/main/java/stirling/software/SPDF/config/security/database/DatabaseService.java +++ b/src/main/java/stirling/software/SPDF/config/security/database/DatabaseService.java @@ -246,26 +246,28 @@ public class DatabaseService implements DatabaseInterface { boolean isDBUrlH2 = datasource.getCustomDatabaseUrl().contains("h2") || datasource.getCustomDatabaseUrl().contains("H2"); + boolean isCustomDatabase = datasource.isEnableCustomDatabase(); - if (isTypeH2 && !isDBUrlH2) { - log.warn( - "Datasource type is H2, but the URL does not contain 'h2'. " - + "Please check your configuration."); - throw new IllegalStateException( - "Datasource type is H2, but the URL does not contain 'h2'. Please check your" - + " configuration."); - } else if (!isTypeH2 && isDBUrlH2) { - log.warn( - "Datasource URL contains 'h2', but the type is not H2. " - + "Please check your configuration."); - throw new IllegalStateException( - "Datasource URL contains 'h2', but the type is not H2. Please check your" - + " configuration."); + if (isCustomDatabase) { + if (isTypeH2 && !isDBUrlH2) { + log.warn( + "Datasource type is H2, but the URL does not contain 'h2'. " + + "Please check your configuration."); + throw new IllegalStateException( + "Datasource type is H2, but the URL does not contain 'h2'. Please check" + + " your configuration."); + } else if (!isTypeH2 && isDBUrlH2) { + log.warn( + "Datasource URL contains 'h2', but the type is not H2. " + + "Please check your configuration."); + throw new IllegalStateException( + "Datasource URL contains 'h2', but the type is not H2. Please check your" + + " configuration."); + } } - boolean isH2 = isTypeH2 && isDBUrlH2; - return !datasource.isEnableCustomDatabase() || isH2; + return !isCustomDatabase || isH2; } /** diff --git a/src/main/java/stirling/software/SPDF/controller/api/misc/ReplaceAndInvertColorController.java b/src/main/java/stirling/software/SPDF/controller/api/misc/ReplaceAndInvertColorController.java index 927b3a51f..865724a74 100644 --- a/src/main/java/stirling/software/SPDF/controller/api/misc/ReplaceAndInvertColorController.java +++ b/src/main/java/stirling/software/SPDF/controller/api/misc/ReplaceAndInvertColorController.java @@ -25,7 +25,7 @@ import stirling.software.SPDF.service.misc.ReplaceAndInvertColorService; @RequiredArgsConstructor public class ReplaceAndInvertColorController { - private ReplaceAndInvertColorService replaceAndInvertColorService; + private final ReplaceAndInvertColorService replaceAndInvertColorService; @PostMapping(consumes = "multipart/form-data", value = "/replace-invert-pdf") @Operation( diff --git a/src/main/java/stirling/software/SPDF/service/misc/ReplaceAndInvertColorService.java b/src/main/java/stirling/software/SPDF/service/misc/ReplaceAndInvertColorService.java index 20c20eb7b..e2a4e7ea5 100644 --- a/src/main/java/stirling/software/SPDF/service/misc/ReplaceAndInvertColorService.java +++ b/src/main/java/stirling/software/SPDF/service/misc/ReplaceAndInvertColorService.java @@ -16,7 +16,7 @@ import stirling.software.SPDF.utils.misc.ReplaceAndInvertColorStrategy; @Service @RequiredArgsConstructor public class ReplaceAndInvertColorService { - private ReplaceAndInvertColorFactory replaceAndInvertColorFactory; + private final ReplaceAndInvertColorFactory replaceAndInvertColorFactory; public InputStreamResource replaceAndInvertColor( MultipartFile file, diff --git a/src/main/resources/messages_it_IT.properties b/src/main/resources/messages_it_IT.properties index 3c654ddb5..9e2a54af4 100644 --- a/src/main/resources/messages_it_IT.properties +++ b/src/main/resources/messages_it_IT.properties @@ -609,7 +609,7 @@ login.userIsDisabled=L'utente è disattivato, l'accesso è attualmente bloccato login.alreadyLoggedIn=Hai già effettuato l'accesso a login.alreadyLoggedIn2=dispositivi. Esci dai dispositivi e riprova. login.toManySessions=Hai troppe sessioni attive -login.logoutMessage=You have been logged out. +login.logoutMessage=Sei stato disconnesso. #auto-redact autoRedact.title=Redazione automatica diff --git a/src/main/resources/static/3rdPartyLicenses.json b/src/main/resources/static/3rdPartyLicenses.json index 4d1c7bfb5..c20671d97 100644 --- a/src/main/resources/static/3rdPartyLicenses.json +++ b/src/main/resources/static/3rdPartyLicenses.json @@ -871,7 +871,7 @@ { "moduleName": "org.apache.pdfbox:fontbox", "moduleUrl": "https://pdfbox.apache.org", - "moduleVersion": "3.0.4", + "moduleVersion": "3.0.5", "moduleLicense": "Apache-2.0", "moduleLicenseUrl": "https://www.apache.org/licenses/LICENSE-2.0.txt" }, @@ -884,28 +884,28 @@ { "moduleName": "org.apache.pdfbox:pdfbox", "moduleUrl": "https://pdfbox.apache.org", - "moduleVersion": "3.0.4", + "moduleVersion": "3.0.5", "moduleLicense": "Apache-2.0", "moduleLicenseUrl": "https://www.apache.org/licenses/LICENSE-2.0.txt" }, { "moduleName": "org.apache.pdfbox:pdfbox-io", "moduleUrl": "https://pdfbox.apache.org", - "moduleVersion": "3.0.4", + "moduleVersion": "3.0.5", "moduleLicense": "Apache-2.0", "moduleLicenseUrl": "https://www.apache.org/licenses/LICENSE-2.0.txt" }, { "moduleName": "org.apache.pdfbox:preflight", "moduleUrl": "https://pdfbox.apache.org", - "moduleVersion": "3.0.4", + "moduleVersion": "3.0.5", "moduleLicense": "Apache-2.0", "moduleLicenseUrl": "https://www.apache.org/licenses/LICENSE-2.0.txt" }, { "moduleName": "org.apache.pdfbox:xmpbox", "moduleUrl": "https://pdfbox.apache.org", - "moduleVersion": "3.0.4", + "moduleVersion": "3.0.5", "moduleLicense": "Apache-2.0", "moduleLicenseUrl": "https://www.apache.org/licenses/LICENSE-2.0.txt" }, diff --git a/src/main/resources/templates/fragments/languages.html b/src/main/resources/templates/fragments/languages.html index 939e5ad6f..3a01449c9 100644 --- a/src/main/resources/templates/fragments/languages.html +++ b/src/main/resources/templates/fragments/languages.html @@ -13,24 +13,24 @@
- - + + - - - + + + - +