mirror of
https://github.com/btcpayserver/btcpayserver.git
synced 2025-03-12 02:08:32 +01:00
27 lines
767 B
C#
27 lines
767 B
C#
|
using BTCPayServer.Data;
|
||
|
using Microsoft.EntityFrameworkCore;
|
||
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
||
|
using Microsoft.EntityFrameworkCore.Migrations;
|
||
|
|
||
|
#nullable disable
|
||
|
|
||
|
namespace BTCPayServer.Migrations
|
||
|
{
|
||
|
[DbContext(typeof(ApplicationDbContext))]
|
||
|
[Migration("20240220000000_FixWalletObjectsWithEmptyWalletId")]
|
||
|
public partial class FixWalletObjectsWithEmptyWalletId : Migration
|
||
|
{
|
||
|
protected override void Up(MigrationBuilder migrationBuilder)
|
||
|
{
|
||
|
if (migrationBuilder.IsNpgsql())
|
||
|
{
|
||
|
migrationBuilder.Sql("DELETE FROM \"WalletObjects\" WHERE \"WalletId\"='';");
|
||
|
}
|
||
|
}
|
||
|
|
||
|
protected override void Down(MigrationBuilder migrationBuilder)
|
||
|
{
|
||
|
}
|
||
|
}
|
||
|
}
|