mirror of
https://github.com/opensim/opensim.git
synced 2026-08-04 16:22:50 +08:00
Update svn properties, clean up formatting, refactor out duplicate hard-coded port numbers.
This commit is contained in:
@@ -129,9 +129,12 @@ namespace OpenSim.Data
|
||||
cmd.CommandText = kvp.Value;
|
||||
cmd.ExecuteNonQuery();
|
||||
|
||||
if (version == 0) {
|
||||
if (version == 0)
|
||||
{
|
||||
InsertVersion(_type, newversion);
|
||||
} else {
|
||||
}
|
||||
else
|
||||
{
|
||||
UpdateVersion(_type, newversion);
|
||||
}
|
||||
version = newversion;
|
||||
@@ -149,7 +152,7 @@ namespace OpenSim.Data
|
||||
if (m.Success)
|
||||
{
|
||||
int MigrationVersion = int.Parse(m.Groups[1].ToString());
|
||||
if ( MigrationVersion > max )
|
||||
if (MigrationVersion > max)
|
||||
max = MigrationVersion;
|
||||
}
|
||||
}
|
||||
@@ -160,9 +163,12 @@ namespace OpenSim.Data
|
||||
{
|
||||
get { return FindVersion(_type); }
|
||||
set {
|
||||
if (Version < 1) {
|
||||
if (Version < 1)
|
||||
{
|
||||
InsertVersion(_type, value);
|
||||
} else {
|
||||
}
|
||||
else
|
||||
{
|
||||
UpdateVersion(_type, value);
|
||||
}
|
||||
}
|
||||
@@ -172,7 +178,8 @@ namespace OpenSim.Data
|
||||
{
|
||||
int version = 0;
|
||||
DbCommand cmd = _conn.CreateCommand();
|
||||
try {
|
||||
try
|
||||
{
|
||||
cmd.CommandText = "select version from migrations where name='" + type + "' limit 1";
|
||||
using (IDataReader reader = cmd.ExecuteReader())
|
||||
{
|
||||
@@ -182,7 +189,9 @@ namespace OpenSim.Data
|
||||
}
|
||||
reader.Close();
|
||||
}
|
||||
} catch {
|
||||
}
|
||||
catch
|
||||
{
|
||||
// Something went wrong, so we're version 0
|
||||
}
|
||||
return version;
|
||||
|
||||
@@ -132,7 +132,7 @@ namespace OpenSim.Data.MySQL
|
||||
|
||||
// if there are no tables, get out of here and let
|
||||
// migrations do their job
|
||||
if(
|
||||
if (
|
||||
tableList["inventoryfolders"] == null &&
|
||||
tableList["inventoryitems"] == null
|
||||
)
|
||||
|
||||
@@ -138,7 +138,7 @@ namespace OpenSim.Data.MySQL
|
||||
|
||||
// if there are no tables, get out of here and let
|
||||
// migrations do their job
|
||||
if(
|
||||
if (
|
||||
tableList[m_agentsTableName] == null &&
|
||||
tableList[m_usersTableName] == null &&
|
||||
tableList[m_userFriendsTableName] == null &&
|
||||
|
||||
Reference in New Issue
Block a user