1
0
Fork 0
mirror of https://github.com/Radarr/Radarr synced 2024-12-28 02:40:01 +00:00
Radarr/NzbDrone.Services/NzbDrone.Services.Service/Datastore/Connection.cs

29 lines
607 B
C#
Raw Normal View History

using System.Configuration;
using System.Linq;
using Services.PetaPoco;
namespace NzbDrone.Services.Service.Datastore
{
public static class Connection
{
public static string GetConnectionString
{
get { return ConfigurationManager.ConnectionStrings["SqlExpress"].ConnectionString; }
}
public static IDatabase GetPetaPocoDb()
{
var db = new Database("SqlExpress")
{
KeepConnectionAlive = false,
ForceDateTimesToUtc = false,
};
return db;
}
}
}