Skip to content

Commit

Permalink
fix: Do not use NonSqlReservedWord constraint on NodeType names, it i…
Browse files Browse the repository at this point in the history
…s too strict
  • Loading branch information
ambroisemaupate committed Jan 10, 2025
1 parent 48b083b commit efe08c1
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 73 deletions.
1 change: 0 additions & 1 deletion lib/RoadizCoreBundle/src/Entity/NodeType.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ class NodeType extends AbstractEntity implements NodeTypeInterface
Serializer\Type('string'),
Assert\NotNull(),
Assert\NotBlank(),
RoadizAssert\NonSqlReservedWord(),
RoadizAssert\SimpleLatinString(),
// Limit discriminator column to 30 characters for indexing optimization
Assert\Length(max: 30)
Expand Down
72 changes: 0 additions & 72 deletions lib/RoadizCoreBundle/src/Form/Constraint/NonSqlReservedWord.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ class NonSqlReservedWord extends Constraint
'active',
'add',
'admin',
'admin',
'after',
'against',
'aggregate',
Expand All @@ -39,7 +38,6 @@ class NonSqlReservedWord extends Constraint
'and',
'any',
'array',
'array',
'as',
'asc',
'ascii',
Expand Down Expand Up @@ -280,7 +278,6 @@ class NonSqlReservedWord extends Constraint
'import',
'in',
'inactive',
'inactive',
'index',
'indexes',
'infile',
Expand Down Expand Up @@ -404,7 +401,6 @@ class NonSqlReservedWord extends Constraint
'mediumint',
'mediumtext',
'member',
'member',
'memory',
'merge',
'message_text',
Expand Down Expand Up @@ -450,21 +446,15 @@ class NonSqlReservedWord extends Constraint
'nth_value',
'nth_value',
'ntile',
'ntile',
'null',
'nulls',
'nulls',
'number',
'numeric',
'nvarchar',
'of',
'of',
'off',
'off',
'offset',
'oj',
'oj',
'old',
'old',
'on',
'one',
Expand All @@ -474,22 +464,17 @@ class NonSqlReservedWord extends Constraint
'optimizer_costs',
'option',
'optional',
'optional',
'optionally',
'options',
'or',
'order',
'ordinality',
'ordinality',
'organization',
'organization',
'others',
'others',
'out',
'outer',
'outfile',
'over',
'over',
'owner',
'pack_keys',
'page',
Expand All @@ -500,14 +485,9 @@ class NonSqlReservedWord extends Constraint
'partitions',
'password',
'password_lock_time',
'password_lock_time',
'path',
'path',
'percent_rank',
'percent_rank',
'persist',
'persist',
'persist_only',
'persist_only',
'phase',
'plugin',
Expand All @@ -518,18 +498,15 @@ class NonSqlReservedWord extends Constraint
'port',
'precedes',
'preceding',
'preceding',
'precision',
'prepare',
'preserve',
'prev',
'primary',
'privilege_checks_user',
'privilege_checks_user',
'privileges',
'procedure',
'process',
'process',
'processlist',
'profile',
'profiles',
Expand All @@ -539,10 +516,8 @@ class NonSqlReservedWord extends Constraint
'query',
'quick',
'random',
'random',
'range',
'rank',
'rank',
'read',
'read_only',
'read_write',
Expand All @@ -551,16 +526,13 @@ class NonSqlReservedWord extends Constraint
'rebuild',
'recover',
'recursive',
'recursive',
'redo_buffer_size',
'redofile',
'redundant',
'reference',
'reference',
'references',
'regexp',
'registration',
'registration',
'relay',
'relay_log_file',
'relay_log_pos',
Expand All @@ -577,8 +549,6 @@ class NonSqlReservedWord extends Constraint
'repeatable',
'replace',
'replica',
'replica',
'replicas',
'replicas',
'replicate_do_db',
'replicate_do_table',
Expand All @@ -594,20 +564,15 @@ class NonSqlReservedWord extends Constraint
'reset',
'resignal',
'resource',
'resource',
'respect',
'respect',
'restart',
'restart',
'restore',
'restrict',
'resume',
'retain',
'retain',
'return',
'returned_sqlstate',
'returning',
'returning',
'returns',
'reuse',
'reuse',
Expand All @@ -616,7 +581,6 @@ class NonSqlReservedWord extends Constraint
'right',
'rlike',
'role',
'role',
'rollback',
'rollup',
'rotate',
Expand All @@ -636,14 +600,9 @@ class NonSqlReservedWord extends Constraint
'second',
'second_microsecond',
'secondary',
'secondary',
'secondary_engine',
'secondary_engine',
'secondary_engine_attribute',
'secondary_engine_attribute',
'secondary_load',
'secondary_load',
'secondary_unload',
'secondary_unload',
'security',
'select',
Expand Down Expand Up @@ -672,56 +631,30 @@ class NonSqlReservedWord extends Constraint
'sounds',
'source',
'source_auto_position',
'source_auto_position',
'source_bind',
'source_bind',
'source_compression_algorithms',
'source_compression_algorithms',
'source_connect_retry',
'source_connect_retry',
'source_delay',
'source_delay',
'source_heartbeat_period',
'source_heartbeat_period',
'source_host',
'source_host',
'source_log_file',
'source_log_file',
'source_log_pos',
'source_log_pos',
'source_password',
'source_password',
'source_port',
'source_port',
'source_public_key_path',
'source_public_key_path',
'source_retry_count',
'source_retry_count',
'source_ssl',
'source_ssl',
'source_ssl_ca',
'source_ssl_ca',
'source_ssl_capath',
'source_ssl_capath',
'source_ssl_cert',
'source_ssl_cert',
'source_ssl_cipher',
'source_ssl_cipher',
'source_ssl_crl',
'source_ssl_crl',
'source_ssl_crlpath',
'source_ssl_crlpath',
'source_ssl_key',
'source_ssl_key',
'source_ssl_verify_server_cert',
'source_ssl_verify_server_cert',
'source_tls_ciphersuites',
'source_tls_ciphersuites',
'source_tls_version',
'source_tls_version',
'source_user',
'source_user',
'source_zstd_compression_level',
'source_zstd_compression_level',
'spatial',
'specific',
Expand Down Expand Up @@ -762,7 +695,6 @@ class NonSqlReservedWord extends Constraint
'stored',
'straight_join',
'stream',
'stream',
'string',
'subclass_origin',
'subject',
Expand All @@ -773,7 +705,6 @@ class NonSqlReservedWord extends Constraint
'swaps',
'switches',
'system',
'system',
'table',
'table_checksum',
'table_name',
Expand All @@ -783,11 +714,8 @@ class NonSqlReservedWord extends Constraint
'temptable',
'terminated',
'text',
'than',
'then',
'thread_priority',
'thread_priority',
'ties',
'ties',
'time',
'timestamp',
Expand Down

0 comments on commit efe08c1

Please sign in to comment.