diff --git a/Logic/Financial/FinancialAccount.cs b/Logic/Financial/FinancialAccount.cs index 007eb8b5..76dcd7f4 100644 --- a/Logic/Financial/FinancialAccount.cs +++ b/Logic/Financial/FinancialAccount.cs @@ -300,7 +300,7 @@ namespace Swarmops.Logic.Financial foreach (FinancialAccountRow row in testRows) { - if (row.Transaction.Description == initialBalanceTransactionTitle) + if (row.Transaction.Description == initialBalanceTransactionTitle && row.FinancialAccountId == this.Identity) { lastFoundRow = row.TransactionRow; } diff --git a/Site/Master-v5.master.cs b/Site/Master-v5.master.cs index 6e3a5a4c..c7dc636f 100644 --- a/Site/Master-v5.master.cs +++ b/Site/Master-v5.master.cs @@ -43,14 +43,19 @@ namespace Swarmops.Frontend // END TEST CODE + // If organization doesn't exist anymore, sign out - if (this._authority.Organization.Identity == 3 && - PilotInstallationIds.IsPilot (PilotInstallationIds.PiratePartySE)) + try + { + this._authority.Organization.GetMemberCount(); // will throw if Organization can't be looked up + } + catch (Exception) { this._authority = null; FormsAuthentication.SignOut(); Response.Redirect("/", true); } + } protected void Page_Load (object sender, EventArgs e)