diff --git a/src/Infrastructure.EntityFramework/AdminConsole/Repositories/OrganizationRepository.cs b/src/Infrastructure.EntityFramework/AdminConsole/Repositories/OrganizationRepository.cs
index 894c3ed620..a236ce74b2 100644
--- a/src/Infrastructure.EntityFramework/AdminConsole/Repositories/OrganizationRepository.cs
+++ b/src/Infrastructure.EntityFramework/AdminConsole/Repositories/OrganizationRepository.cs
@@ -10,7 +10,6 @@ using Bit.Core.Enums;
using Bit.Core.Models.Data.Organizations;
using Bit.Core.Models.Data.Organizations.OrganizationUsers;
using Bit.Core.Repositories;
-using Bit.Infrastructure.EntityFramework.Models;
using LinqToDB.Tools;
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.DependencyInjection;
diff --git a/util/MySqlMigrations/Migrations/20251226224144_DefaultCollectionOwnerIdColumn.cs b/util/MySqlMigrations/Migrations/20251226224144_DefaultCollectionOwnerIdColumn.cs
index e0b8a39796..90d163256b 100644
--- a/util/MySqlMigrations/Migrations/20251226224144_DefaultCollectionOwnerIdColumn.cs
+++ b/util/MySqlMigrations/Migrations/20251226224144_DefaultCollectionOwnerIdColumn.cs
@@ -1,52 +1,50 @@
-using System;
-using Microsoft.EntityFrameworkCore.Migrations;
+using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
-namespace Bit.MySqlMigrations.Migrations
+namespace Bit.MySqlMigrations.Migrations;
+
+///
+public partial class DefaultCollectionOwnerIdColumn : Migration
{
///
- public partial class DefaultCollectionOwnerIdColumn : Migration
+ protected override void Up(MigrationBuilder migrationBuilder)
{
- ///
- protected override void Up(MigrationBuilder migrationBuilder)
- {
- migrationBuilder.AddColumn(
- name: "DefaultCollectionOwnerId",
- table: "Collection",
- type: "char(36)",
- nullable: true,
- collation: "ascii_general_ci");
+ migrationBuilder.AddColumn(
+ name: "DefaultCollectionOwnerId",
+ table: "Collection",
+ type: "char(36)",
+ nullable: true,
+ collation: "ascii_general_ci");
- migrationBuilder.CreateIndex(
- name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
- table: "Collection",
- columns: new[] { "DefaultCollectionOwnerId", "OrganizationId", "Type" },
- unique: true,
- filter: "\"Type\" = 1");
+ migrationBuilder.CreateIndex(
+ name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
+ table: "Collection",
+ columns: new[] { "DefaultCollectionOwnerId", "OrganizationId", "Type" },
+ unique: true,
+ filter: "\"Type\" = 1");
- migrationBuilder.AddForeignKey(
- name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
- table: "Collection",
- column: "DefaultCollectionOwnerId",
- principalTable: "OrganizationUser",
- principalColumn: "Id");
- }
+ migrationBuilder.AddForeignKey(
+ name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
+ table: "Collection",
+ column: "DefaultCollectionOwnerId",
+ principalTable: "OrganizationUser",
+ principalColumn: "Id");
+ }
- ///
- protected override void Down(MigrationBuilder migrationBuilder)
- {
- migrationBuilder.DropForeignKey(
- name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
- table: "Collection");
+ ///
+ protected override void Down(MigrationBuilder migrationBuilder)
+ {
+ migrationBuilder.DropForeignKey(
+ name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
+ table: "Collection");
- migrationBuilder.DropIndex(
- name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
- table: "Collection");
+ migrationBuilder.DropIndex(
+ name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
+ table: "Collection");
- migrationBuilder.DropColumn(
- name: "DefaultCollectionOwnerId",
- table: "Collection");
- }
+ migrationBuilder.DropColumn(
+ name: "DefaultCollectionOwnerId",
+ table: "Collection");
}
}
diff --git a/util/PostgresMigrations/Migrations/20251226224149_DefaultCollectionOwnerIdColumn.cs b/util/PostgresMigrations/Migrations/20251226224149_DefaultCollectionOwnerIdColumn.cs
index c1081cfd82..2e2c2b8b5b 100644
--- a/util/PostgresMigrations/Migrations/20251226224149_DefaultCollectionOwnerIdColumn.cs
+++ b/util/PostgresMigrations/Migrations/20251226224149_DefaultCollectionOwnerIdColumn.cs
@@ -1,51 +1,49 @@
-using System;
-using Microsoft.EntityFrameworkCore.Migrations;
+using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
-namespace Bit.PostgresMigrations.Migrations
+namespace Bit.PostgresMigrations.Migrations;
+
+///
+public partial class DefaultCollectionOwnerIdColumn : Migration
{
///
- public partial class DefaultCollectionOwnerIdColumn : Migration
+ protected override void Up(MigrationBuilder migrationBuilder)
{
- ///
- protected override void Up(MigrationBuilder migrationBuilder)
- {
- migrationBuilder.AddColumn(
- name: "DefaultCollectionOwnerId",
- table: "Collection",
- type: "uuid",
- nullable: true);
+ migrationBuilder.AddColumn(
+ name: "DefaultCollectionOwnerId",
+ table: "Collection",
+ type: "uuid",
+ nullable: true);
- migrationBuilder.CreateIndex(
- name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
- table: "Collection",
- columns: new[] { "DefaultCollectionOwnerId", "OrganizationId", "Type" },
- unique: true,
- filter: "\"Type\" = 1");
+ migrationBuilder.CreateIndex(
+ name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
+ table: "Collection",
+ columns: new[] { "DefaultCollectionOwnerId", "OrganizationId", "Type" },
+ unique: true,
+ filter: "\"Type\" = 1");
- migrationBuilder.AddForeignKey(
- name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
- table: "Collection",
- column: "DefaultCollectionOwnerId",
- principalTable: "OrganizationUser",
- principalColumn: "Id");
- }
+ migrationBuilder.AddForeignKey(
+ name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
+ table: "Collection",
+ column: "DefaultCollectionOwnerId",
+ principalTable: "OrganizationUser",
+ principalColumn: "Id");
+ }
- ///
- protected override void Down(MigrationBuilder migrationBuilder)
- {
- migrationBuilder.DropForeignKey(
- name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
- table: "Collection");
+ ///
+ protected override void Down(MigrationBuilder migrationBuilder)
+ {
+ migrationBuilder.DropForeignKey(
+ name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
+ table: "Collection");
- migrationBuilder.DropIndex(
- name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
- table: "Collection");
+ migrationBuilder.DropIndex(
+ name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
+ table: "Collection");
- migrationBuilder.DropColumn(
- name: "DefaultCollectionOwnerId",
- table: "Collection");
- }
+ migrationBuilder.DropColumn(
+ name: "DefaultCollectionOwnerId",
+ table: "Collection");
}
}
diff --git a/util/SqliteMigrations/Migrations/20251226224140_DefaultCollectionOwnerIdColumn.cs b/util/SqliteMigrations/Migrations/20251226224140_DefaultCollectionOwnerIdColumn.cs
index 2163aa1cda..f4c01b74bc 100644
--- a/util/SqliteMigrations/Migrations/20251226224140_DefaultCollectionOwnerIdColumn.cs
+++ b/util/SqliteMigrations/Migrations/20251226224140_DefaultCollectionOwnerIdColumn.cs
@@ -1,51 +1,49 @@
-using System;
-using Microsoft.EntityFrameworkCore.Migrations;
+using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
-namespace Bit.SqliteMigrations.Migrations
+namespace Bit.SqliteMigrations.Migrations;
+
+///
+public partial class DefaultCollectionOwnerIdColumn : Migration
{
///
- public partial class DefaultCollectionOwnerIdColumn : Migration
+ protected override void Up(MigrationBuilder migrationBuilder)
{
- ///
- protected override void Up(MigrationBuilder migrationBuilder)
- {
- migrationBuilder.AddColumn(
- name: "DefaultCollectionOwnerId",
- table: "Collection",
- type: "TEXT",
- nullable: true);
+ migrationBuilder.AddColumn(
+ name: "DefaultCollectionOwnerId",
+ table: "Collection",
+ type: "TEXT",
+ nullable: true);
- migrationBuilder.CreateIndex(
- name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
- table: "Collection",
- columns: new[] { "DefaultCollectionOwnerId", "OrganizationId", "Type" },
- unique: true,
- filter: "\"Type\" = 1");
+ migrationBuilder.CreateIndex(
+ name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
+ table: "Collection",
+ columns: new[] { "DefaultCollectionOwnerId", "OrganizationId", "Type" },
+ unique: true,
+ filter: "\"Type\" = 1");
- migrationBuilder.AddForeignKey(
- name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
- table: "Collection",
- column: "DefaultCollectionOwnerId",
- principalTable: "OrganizationUser",
- principalColumn: "Id");
- }
+ migrationBuilder.AddForeignKey(
+ name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
+ table: "Collection",
+ column: "DefaultCollectionOwnerId",
+ principalTable: "OrganizationUser",
+ principalColumn: "Id");
+ }
- ///
- protected override void Down(MigrationBuilder migrationBuilder)
- {
- migrationBuilder.DropForeignKey(
- name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
- table: "Collection");
+ ///
+ protected override void Down(MigrationBuilder migrationBuilder)
+ {
+ migrationBuilder.DropForeignKey(
+ name: "FK_Collection_OrganizationUser_DefaultCollectionOwnerId",
+ table: "Collection");
- migrationBuilder.DropIndex(
- name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
- table: "Collection");
+ migrationBuilder.DropIndex(
+ name: "IX_Collection_DefaultCollectionOwnerId_OrganizationId_Type",
+ table: "Collection");
- migrationBuilder.DropColumn(
- name: "DefaultCollectionOwnerId",
- table: "Collection");
- }
+ migrationBuilder.DropColumn(
+ name: "DefaultCollectionOwnerId",
+ table: "Collection");
}
}