Many changes, Config depends on Users, not vice versa.
This commit is contained in:
+4
-4
@@ -30,9 +30,9 @@ namespace Results
|
||||
}
|
||||
|
||||
/// <summary> Database type (MySQL or SQLite) for all sessions </summary>
|
||||
private static Config.Entities.DBType dbType;
|
||||
private static Users.Entities.DBType dbType;
|
||||
///
|
||||
public static Config.Entities.DBType DbType
|
||||
public static Users.Entities.DBType DbType
|
||||
{
|
||||
get { return dbType; }
|
||||
set { dbType = value; SessionFactory = null; }
|
||||
@@ -59,10 +59,10 @@ namespace Results
|
||||
switch (dbType)
|
||||
{
|
||||
default:
|
||||
case Config.Entities.DBType.SQLite:
|
||||
case Users.Entities.DBType.SQLite:
|
||||
cfg = cfg.Database(SQLiteConfiguration.Standard.UsingFile(connectionString));
|
||||
break;
|
||||
case Config.Entities.DBType.MySql:
|
||||
case Users.Entities.DBType.MySql:
|
||||
cfg = cfg.Database(MySQLConfiguration.Standard.ConnectionString(connectionString));
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user