drizzle-kit 0.21.1-5071de4 → 0.21.1-c7223b2

Sign up to get free protection for your applications and to get access to all the features.
package/bin.cjs CHANGED
@@ -8652,7 +8652,6 @@ var init_common = __esm({
8652
8652
  literalType("better-sqlite"),
8653
8653
  literalType("turso"),
8654
8654
  literalType("libsql"),
8655
- literalType("d1"),
8656
8655
  literalType("d1-http"),
8657
8656
  literalType("expo")
8658
8657
  ]);
@@ -111520,14 +111519,12 @@ var init_connections = __esm({
111520
111519
  );
111521
111520
  process.exit(1);
111522
111521
  };
111523
- prepareSqliteParams = (params, driver2) => {
111522
+ prepareSqliteParams = (params) => {
111524
111523
  return params.map((param) => {
111525
111524
  if (param && typeof param === "object" && "type" in param && "value" in param && param.type === "binary") {
111526
- const value = typeof param.value === "object" ? JSON.stringify(param.value) : param.value;
111527
- if (driver2 === "d1-http") {
111528
- return value;
111529
- }
111530
- return Buffer.from(value);
111525
+ return Buffer.from(
111526
+ typeof param.value === "object" ? JSON.stringify(param.value) : param.value
111527
+ );
111531
111528
  }
111532
111529
  return param;
111533
111530
  });
@@ -111615,7 +111612,7 @@ var init_connections = __esm({
111615
111612
  };
111616
111613
  const proxy = {
111617
111614
  proxy: async (params) => {
111618
- const preparedParams = prepareSqliteParams(params.params, "d1-http");
111615
+ const preparedParams = prepareSqliteParams(params.params);
111619
111616
  const result = await remoteCallback(params.sql, preparedParams, params.mode === "array" ? "values" : "all");
111620
111617
  return result.rows;
111621
111618
  }
package/index.d.mts CHANGED
@@ -2,7 +2,7 @@ import { SslOptions } from 'mysql2';
2
2
  import * as zod from 'zod';
3
3
  import { TypeOf } from 'zod';
4
4
 
5
- declare const driver: zod.ZodUnion<[zod.ZodUnion<[zod.ZodLiteral<"better-sqlite">, zod.ZodLiteral<"turso">, zod.ZodLiteral<"libsql">, zod.ZodLiteral<"d1">, zod.ZodLiteral<"d1-http">, zod.ZodLiteral<"expo">]>, zod.ZodLiteral<"aws-data-api">, zod.ZodLiteral<"mysql2">]>;
5
+ declare const driver: zod.ZodUnion<[zod.ZodUnion<[zod.ZodLiteral<"better-sqlite">, zod.ZodLiteral<"turso">, zod.ZodLiteral<"libsql">, zod.ZodLiteral<"d1-http">, zod.ZodLiteral<"expo">]>, zod.ZodLiteral<"aws-data-api">, zod.ZodLiteral<"mysql2">]>;
6
6
  type Driver = TypeOf<typeof driver>;
7
7
 
8
8
  declare const dialect: zod.ZodEnum<["postgresql", "mysql", "sqlite"]>;
@@ -164,19 +164,11 @@ type Config = {
164
164
  };
165
165
  } | {
166
166
  dialect: Verify<Dialect, "sqlite">;
167
- driver: Verify<Driver, "d1">;
167
+ driver: Verify<Driver, "d1-http">;
168
168
  dbCredentials: {
169
169
  wranglerConfigPath: string;
170
170
  dbName: string;
171
171
  };
172
- } | {
173
- dialect: Verify<Dialect, "sqlite">;
174
- driver: Verify<Driver, "d1-http">;
175
- dbCredentials: {
176
- accountId: string;
177
- databaseId: string;
178
- token: string;
179
- };
180
172
  } | {
181
173
  dialect: Verify<Dialect, "sqlite">;
182
174
  driver: Verify<Driver, "expo">;
package/index.d.ts CHANGED
@@ -2,7 +2,7 @@ import { SslOptions } from 'mysql2';
2
2
  import * as zod from 'zod';
3
3
  import { TypeOf } from 'zod';
4
4
 
5
- declare const driver: zod.ZodUnion<[zod.ZodUnion<[zod.ZodLiteral<"better-sqlite">, zod.ZodLiteral<"turso">, zod.ZodLiteral<"libsql">, zod.ZodLiteral<"d1">, zod.ZodLiteral<"d1-http">, zod.ZodLiteral<"expo">]>, zod.ZodLiteral<"aws-data-api">, zod.ZodLiteral<"mysql2">]>;
5
+ declare const driver: zod.ZodUnion<[zod.ZodUnion<[zod.ZodLiteral<"better-sqlite">, zod.ZodLiteral<"turso">, zod.ZodLiteral<"libsql">, zod.ZodLiteral<"d1-http">, zod.ZodLiteral<"expo">]>, zod.ZodLiteral<"aws-data-api">, zod.ZodLiteral<"mysql2">]>;
6
6
  type Driver = TypeOf<typeof driver>;
7
7
 
8
8
  declare const dialect: zod.ZodEnum<["postgresql", "mysql", "sqlite"]>;
@@ -164,19 +164,11 @@ type Config = {
164
164
  };
165
165
  } | {
166
166
  dialect: Verify<Dialect, "sqlite">;
167
- driver: Verify<Driver, "d1">;
167
+ driver: Verify<Driver, "d1-http">;
168
168
  dbCredentials: {
169
169
  wranglerConfigPath: string;
170
170
  dbName: string;
171
171
  };
172
- } | {
173
- dialect: Verify<Dialect, "sqlite">;
174
- driver: Verify<Driver, "d1-http">;
175
- dbCredentials: {
176
- accountId: string;
177
- databaseId: string;
178
- token: string;
179
- };
180
172
  } | {
181
173
  dialect: Verify<Dialect, "sqlite">;
182
174
  driver: Verify<Driver, "expo">;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "drizzle-kit",
3
- "version": "0.21.1-5071de4",
3
+ "version": "0.21.1-c7223b2",
4
4
  "repository": "https://github.com/drizzle-team/drizzle-kit-mirror",
5
5
  "author": "Drizzle Team",
6
6
  "license": "MIT",
package/payload.js CHANGED
@@ -8496,7 +8496,6 @@ var init_common2 = __esm({
8496
8496
  (0, import_zod8.literal)("better-sqlite"),
8497
8497
  (0, import_zod8.literal)("turso"),
8498
8498
  (0, import_zod8.literal)("libsql"),
8499
- (0, import_zod8.literal)("d1"),
8500
8499
  (0, import_zod8.literal)("d1-http"),
8501
8500
  (0, import_zod8.literal)("expo")
8502
8501
  ]);
package/payload.mjs CHANGED
@@ -8536,7 +8536,6 @@ var init_common2 = __esm({
8536
8536
  literal6("better-sqlite"),
8537
8537
  literal6("turso"),
8538
8538
  literal6("libsql"),
8539
- literal6("d1"),
8540
8539
  literal6("d1-http"),
8541
8540
  literal6("expo")
8542
8541
  ]);