appwrite-utils-cli 0.9.57 → 0.9.58

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -124,6 +124,7 @@ This updated CLI ensures that developers have robust tools at their fingertips t
124
124
 
125
125
  ## Changelog
126
126
 
127
+ - 0.9.58: The same as before, I just missed it hah
127
128
  - 0.9.57: Changed generated schema type of `$createdAt` and `$updatedAt` to string from `string | Date` cause honestly if you want a date just parse it
128
129
  - 0.9.56: Changed the updateAttribute so it doesn't always update attributes and hopefully fixed the required error
129
130
  - 0.9.55: Updated to use `node-appwrite@14` for appwrite 1.6.0
@@ -233,8 +233,8 @@ export class SchemaGenerator {
233
233
  let schemaString = `${imports}\n\n`;
234
234
  schemaString += `export const ${pascalName}SchemaBase = z.object({\n`;
235
235
  schemaString += ` $id: z.string().optional(),\n`;
236
- schemaString += ` $createdAt: z.date().or(z.string()).optional(),\n`;
237
- schemaString += ` $updatedAt: z.date().or(z.string()).optional(),\n`;
236
+ schemaString += ` $createdAt: z.string().optional(),\n`;
237
+ schemaString += ` $updatedAt: z.string().optional(),\n`;
238
238
  for (const attribute of attributes) {
239
239
  if (attribute.type === "relationship") {
240
240
  continue;
@@ -233,8 +233,8 @@ export class SchemaGenerator {
233
233
  let schemaString = `${imports}\n\n`;
234
234
  schemaString += `export const ${pascalName}SchemaBase = z.object({\n`;
235
235
  schemaString += ` $id: z.string().optional(),\n`;
236
- schemaString += ` $createdAt: z.date().or(z.string()).optional(),\n`;
237
- schemaString += ` $updatedAt: z.date().or(z.string()).optional(),\n`;
236
+ schemaString += ` $createdAt: z.string().optional(),\n`;
237
+ schemaString += ` $updatedAt: z.string().optional(),\n`;
238
238
  for (const attribute of attributes) {
239
239
  if (attribute.type === "relationship") {
240
240
  continue;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "appwrite-utils-cli",
3
3
  "description": "Appwrite Utility Functions to help with database management, data conversion, data import, migrations, and much more. Meant to be used as a CLI tool, I do not recommend installing this in frontend environments.",
4
- "version": "0.9.57",
4
+ "version": "0.9.58",
5
5
  "main": "src/main.ts",
6
6
  "type": "module",
7
7
  "repository": {
@@ -302,8 +302,8 @@ export class SchemaGenerator {
302
302
  let schemaString = `${imports}\n\n`;
303
303
  schemaString += `export const ${pascalName}SchemaBase = z.object({\n`;
304
304
  schemaString += ` $id: z.string().optional(),\n`;
305
- schemaString += ` $createdAt: z.date().or(z.string()).optional(),\n`;
306
- schemaString += ` $updatedAt: z.date().or(z.string()).optional(),\n`;
305
+ schemaString += ` $createdAt: z.string().optional(),\n`;
306
+ schemaString += ` $updatedAt: z.string().optional(),\n`;
307
307
  for (const attribute of attributes) {
308
308
  if (attribute.type === "relationship") {
309
309
  continue;