libeufin

Integration and sandbox testing for FinTech APIs and data formats
Log | Files | Refs | Submodules | README | LICENSE

commit 48c1cc4ce7e338d14093b2e04ccd621282a451ee
parent d72290e523da8aa1dda3f072e3ecf232700f4cfe
Author: MS <ms@taler.net>
Date:   Fri, 28 Jul 2023 17:11:04 +0200

Fix #7890 follow-up.

Diffstat:
Msandbox/src/test/kotlin/DBTest.kt | 1+
Mutil/src/main/kotlin/DB.kt | 2+-
2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/sandbox/src/test/kotlin/DBTest.kt b/sandbox/src/test/kotlin/DBTest.kt @@ -57,6 +57,7 @@ class DBTest { @Test fun connectionStringTest() { var conv = getJdbcConnectionFromPg("postgresql:///libeufincheck") + connectWithSchema(getJdbcConnectionFromPg("postgres:///libeufincheck")) connectWithSchema(conv) conv = getJdbcConnectionFromPg("postgresql://localhost:5432/libeufincheck?user=${System.getProperty("user.name")}") connectWithSchema(conv) diff --git a/util/src/main/kotlin/DB.kt b/util/src/main/kotlin/DB.kt @@ -261,7 +261,7 @@ fun connectWithSchema(jdbcConn: String, schemaName: String? = null) { * sockets need individual intervention. */ fun getJdbcConnectionFromPg(pgConn: String): String { - if (!pgConn.startsWith("postgresql://")) { + if (!pgConn.startsWith("postgresql://") && !pgConn.startsWith("postgres://")) { logger.info("Not a Postgres connection string: $pgConn") throw internalServerError("Not a Postgres connection string: $pgConn") }