fix(ui): schema-library delete-audit name + busy guard + edit-row guard + sanitized create-race test (#260)
This commit is contained in:
@@ -31,8 +31,11 @@ public sealed class SchemaLibraryQueryService : ISchemaLibraryQueryService
|
||||
var repo = scope.ServiceProvider.GetRequiredService<ISharedSchemaRepository>();
|
||||
var all = await repo.ListAsync(cancellationToken);
|
||||
|
||||
// Ordinal-keyed to match the lib:Name resolver's exact-name lookup. Last-wins on
|
||||
// the (DB-unique) name guards against a transient duplicate read.
|
||||
// Ordinal-keyed to match the lib:Name resolver's exact-name lookup. Name is
|
||||
// DB-unique, so a list yields at most one row per name and no real collision
|
||||
// occurs; the indexer assignment is defensive only — should two rows ever share
|
||||
// a name (e.g. a mid-write transient read), the later one in enumeration order
|
||||
// overwrites the earlier rather than throwing.
|
||||
var map = new Dictionary<string, string>(StringComparer.Ordinal);
|
||||
foreach (var schema in all)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user