20241112234144_FixMediaStreams2.cs 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144
  1. using Microsoft.EntityFrameworkCore.Migrations;
  2. #nullable disable
  3. namespace Jellyfin.Server.Implementations.Migrations
  4. {
  5. /// <inheritdoc />
  6. public partial class FixMediaStreams2 : Migration
  7. {
  8. /// <inheritdoc />
  9. protected override void Up(MigrationBuilder migrationBuilder)
  10. {
  11. migrationBuilder.AlterColumn<string>(
  12. name: "Profile",
  13. table: "MediaStreamInfos",
  14. type: "TEXT",
  15. nullable: true,
  16. oldClrType: typeof(string),
  17. oldType: "TEXT");
  18. migrationBuilder.AlterColumn<string>(
  19. name: "Path",
  20. table: "MediaStreamInfos",
  21. type: "TEXT",
  22. nullable: true,
  23. oldClrType: typeof(string),
  24. oldType: "TEXT");
  25. migrationBuilder.AlterColumn<string>(
  26. name: "Language",
  27. table: "MediaStreamInfos",
  28. type: "TEXT",
  29. nullable: true,
  30. oldClrType: typeof(string),
  31. oldType: "TEXT");
  32. migrationBuilder.AlterColumn<bool>(
  33. name: "IsInterlaced",
  34. table: "MediaStreamInfos",
  35. type: "INTEGER",
  36. nullable: true,
  37. oldClrType: typeof(bool),
  38. oldType: "INTEGER");
  39. migrationBuilder.AlterColumn<string>(
  40. name: "Codec",
  41. table: "MediaStreamInfos",
  42. type: "TEXT",
  43. nullable: true,
  44. oldClrType: typeof(string),
  45. oldType: "TEXT");
  46. migrationBuilder.AlterColumn<string>(
  47. name: "ChannelLayout",
  48. table: "MediaStreamInfos",
  49. type: "TEXT",
  50. nullable: true,
  51. oldClrType: typeof(string),
  52. oldType: "TEXT");
  53. migrationBuilder.AlterColumn<string>(
  54. name: "AspectRatio",
  55. table: "MediaStreamInfos",
  56. type: "TEXT",
  57. nullable: true,
  58. oldClrType: typeof(string),
  59. oldType: "TEXT");
  60. }
  61. /// <inheritdoc />
  62. protected override void Down(MigrationBuilder migrationBuilder)
  63. {
  64. migrationBuilder.AlterColumn<string>(
  65. name: "Profile",
  66. table: "MediaStreamInfos",
  67. type: "TEXT",
  68. nullable: false,
  69. defaultValue: string.Empty,
  70. oldClrType: typeof(string),
  71. oldType: "TEXT",
  72. oldNullable: true);
  73. migrationBuilder.AlterColumn<string>(
  74. name: "Path",
  75. table: "MediaStreamInfos",
  76. type: "TEXT",
  77. nullable: false,
  78. defaultValue: string.Empty,
  79. oldClrType: typeof(string),
  80. oldType: "TEXT",
  81. oldNullable: true);
  82. migrationBuilder.AlterColumn<string>(
  83. name: "Language",
  84. table: "MediaStreamInfos",
  85. type: "TEXT",
  86. nullable: false,
  87. defaultValue: string.Empty,
  88. oldClrType: typeof(string),
  89. oldType: "TEXT",
  90. oldNullable: true);
  91. migrationBuilder.AlterColumn<bool>(
  92. name: "IsInterlaced",
  93. table: "MediaStreamInfos",
  94. type: "INTEGER",
  95. nullable: false,
  96. defaultValue: false,
  97. oldClrType: typeof(bool),
  98. oldType: "INTEGER",
  99. oldNullable: true);
  100. migrationBuilder.AlterColumn<string>(
  101. name: "Codec",
  102. table: "MediaStreamInfos",
  103. type: "TEXT",
  104. nullable: false,
  105. defaultValue: string.Empty,
  106. oldClrType: typeof(string),
  107. oldType: "TEXT",
  108. oldNullable: true);
  109. migrationBuilder.AlterColumn<string>(
  110. name: "ChannelLayout",
  111. table: "MediaStreamInfos",
  112. type: "TEXT",
  113. nullable: false,
  114. defaultValue: string.Empty,
  115. oldClrType: typeof(string),
  116. oldType: "TEXT",
  117. oldNullable: true);
  118. migrationBuilder.AlterColumn<string>(
  119. name: "AspectRatio",
  120. table: "MediaStreamInfos",
  121. type: "TEXT",
  122. nullable: false,
  123. defaultValue: string.Empty,
  124. oldClrType: typeof(string),
  125. oldType: "TEXT",
  126. oldNullable: true);
  127. }
  128. }
  129. }