Files
Shadow/Tools/GeneralUseHelperFunctions.cs
sherl defa00d0d3
All checks were successful
Update changelog / changelog (push) Successful in 26s
feat: add setup wizard and proper seeder
2025-12-16 04:02:42 +01:00

31 lines
770 B
C#

using Microsoft.EntityFrameworkCore;
using Shadow.Data;
using Shadow.Entities;
using System.Text;
namespace Shadow.Tools;
public class GeneralUseHelpers(ApplicationDbContext db, IConfiguration appsettings)
{
private readonly ApplicationDbContext _db = db;
private readonly IConfiguration _appsettings = appsettings;
//async public Task<User?> GetUserFromEmail(string email)
//{
// return await _db.Users.FirstOrDefaultAsync(e => e.Email == email);
//}
//public string HashWithSHA512(string s)
//{
// using (var sha512 = SHA512.Create())
// {
// byte[] bytes = Encoding.ASCII.GetBytes(s);
// byte[] hash = sha512.ComputeHash(bytes);
// string hashstring = BitConverter.ToString(hash).Replace("-", "").ToLower();
// return hashstring;
// }
//}
}