Skip to content

Commit

Permalink
Regex correction to allow
Browse files Browse the repository at this point in the history
dot(in postgreSql)
-(in PostgreSQL/SQLite/SQL Server) with double qoute or with backticks in MySql
  • Loading branch information
ahmadasjad committed Sep 19, 2024
1 parent ca67155 commit 01ced8a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Generator/ActiveRecord/Command.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public function __construct(
private readonly string $namespace = 'App\\Model',
#[Required]
#[Regex(
pattern: '/^[a-z_][a-z0-9_]*$/i',
pattern: '/^[\w-]+(?:\.[\w-]+)?$/i',
message: 'Invalid table name'
)]
#[TableExistsRule]
Expand Down

0 comments on commit 01ced8a

Please sign in to comment.