Merge branch 'master' into master
This commit is contained in:
@ -419,6 +419,7 @@ namespace Oqtane.Infrastructure
|
|||||||
{
|
{
|
||||||
using (var db = new InstallationContext(connectionString))
|
using (var db = new InstallationContext(connectionString))
|
||||||
{
|
{
|
||||||
|
|
||||||
//check if DbUp was initialized
|
//check if DbUp was initialized
|
||||||
return TableExists(db, "SchemaVersions");
|
return TableExists(db, "SchemaVersions");
|
||||||
}
|
}
|
||||||
@ -431,6 +432,7 @@ namespace Oqtane.Infrastructure
|
|||||||
|
|
||||||
public static bool TableExists(DbContext context, string schema, string tableName)
|
public static bool TableExists(DbContext context, string schema, string tableName)
|
||||||
{
|
{
|
||||||
|
if (!context.Database.CanConnect()) return false;
|
||||||
var connection = context.Database.GetDbConnection();
|
var connection = context.Database.GetDbConnection();
|
||||||
|
|
||||||
if (connection.State.Equals(ConnectionState.Closed))
|
if (connection.State.Equals(ConnectionState.Closed))
|
||||||
|
@ -2,9 +2,9 @@
|
|||||||
"ConnectionStrings": {
|
"ConnectionStrings": {
|
||||||
"DefaultConnection": ""
|
"DefaultConnection": ""
|
||||||
},
|
},
|
||||||
|
"Runtime" : "Server",
|
||||||
"Installation": {
|
"Installation": {
|
||||||
"DefaultAlias": "",
|
"DefaultAlias": "",
|
||||||
"HostUser": "",
|
|
||||||
"HostPassword": "",
|
"HostPassword": "",
|
||||||
"HostEmail": "",
|
"HostEmail": "",
|
||||||
"SiteTemplate": "",
|
"SiteTemplate": "",
|
||||||
|
Reference in New Issue
Block a user