[DB] Allow mentioning 'note' in a DQL query (in quotes), in order to be able to search in the activity table (previously would be replaced by the class name)

This commit is contained in:
Hugo Sales 2021-12-21 12:44:34 +00:00
parent 85735222cb
commit 7f65b23074
Signed by: someonewithpc
GPG Key ID: 7D0C7EAFC9D835A0

View File

@ -84,7 +84,7 @@ class DB
}
self::$sql_table_entity_pattern = '/(' . implode('|', array_keys(self::$table_map)) . ')\s([^\s]+)/';
self::$dql_table_name_patterns = F\map(self::$table_map, fn ($_, $s) => "/(?<!\\.)\\b{$s}\\b/");
self::$dql_table_name_patterns = F\map(self::$table_map, fn ($_, $s) => "/(?<![\\.'])\\b{$s}\\b/");
}
public static function getTableForClass(string $class)