[CHANGE] Remove anon accounts && added simple caching for urls

This commit is contained in:
max
2025-09-17 23:44:02 +02:00
parent 0056a14f79
commit 8a64d6fc64
15 changed files with 235 additions and 50 deletions

View File

@@ -0,0 +1,25 @@
using Manager.Data.Entities.Cache;
using Microsoft.EntityFrameworkCore;
namespace Manager.Data.Contexts;
public sealed class CacheDbContext : DbContext
{
public CacheDbContext(DbContextOptions<CacheDbContext> options) : base(options)
{
Database.EnsureCreated();
}
public DbSet<CacheEntity> Cache { get; set; }
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
modelBuilder.Entity<CacheEntity>(ce =>
{
ce.ToTable("cache");
ce.HasKey(x => x.Id);
});
base.OnModelCreating(modelBuilder);
}
}