launchbase 1.1.8 → 1.1.9

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/bin/launchbase.js CHANGED
@@ -7,7 +7,7 @@ const crypto = require('crypto');
7
7
  const fs = require('fs-extra');
8
8
  const { execSync, spawn } = require('child_process');
9
9
 
10
- const VERSION = '1.1.8';
10
+ const VERSION = '1.1.9';
11
11
  const program = new Command();
12
12
 
13
13
  function findAvailablePort(startPort = 5432, maxAttempts = 100) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "launchbase",
3
- "version": "1.1.8",
3
+ "version": "1.1.9",
4
4
  "description": "Generate production-ready NestJS backends with authentication, multi-tenancy, billing, and deployment in minutes",
5
5
  "author": "LaunchBase",
6
6
  "keywords": [
@@ -1,7 +1,13 @@
1
- import { IsString, MinLength } from 'class-validator';
1
+ import { IsString, IsOptional, MinLength, MaxLength } from 'class-validator';
2
2
 
3
3
  export class CreateProjectDto {
4
4
  @IsString()
5
5
  @MinLength(2)
6
+ @MaxLength(100)
6
7
  name!: string;
8
+
9
+ @IsOptional()
10
+ @IsString()
11
+ @MaxLength(500)
12
+ description?: string;
7
13
  }
@@ -1,8 +1,14 @@
1
- import { IsOptional, IsString, MinLength } from 'class-validator';
1
+ import { IsOptional, IsString, MinLength, MaxLength } from 'class-validator';
2
2
 
3
3
  export class UpdateProjectDto {
4
4
  @IsOptional()
5
5
  @IsString()
6
6
  @MinLength(2)
7
+ @MaxLength(100)
7
8
  name?: string;
9
+
10
+ @IsOptional()
11
+ @IsString()
12
+ @MaxLength(500)
13
+ description?: string;
8
14
  }
@@ -21,7 +21,7 @@ export class ProjectsService {
21
21
  const slug = dto.name.toLowerCase().replace(/[^a-z0-9]+/g, '-').replace(/^-|-$/g, '');
22
22
 
23
23
  const project = await this.prisma.project.create({
24
- data: { organizationId, name: dto.name, slug }
24
+ data: { organizationId, name: dto.name, slug, description: dto.description }
25
25
  });
26
26
 
27
27
  return { project };
@@ -34,7 +34,10 @@ export class ProjectsService {
34
34
 
35
35
  const updated = await this.prisma.project.update({
36
36
  where: { id },
37
- data: { name: dto.name ?? project.name }
37
+ data: {
38
+ name: dto.name ?? project.name,
39
+ description: dto.description ?? project.description,
40
+ }
38
41
  });
39
42
 
40
43
  return { project: updated };