@@ -493,15 +493,16 @@ public static function insertChat(Chat $chat, ?string $date = null, ?int $migrat
493493 try {
494494 $ sth = self ::$ pdo ->prepare ('
495495 INSERT IGNORE INTO ` ' . TB_CHAT . '`
496- (`id`, `type`, `title`, `username`, `first_name`, `last_name`, `created_at` ,`updated_at`, `old_id`)
496+ (`id`, `type`, `title`, `username`, `first_name`, `last_name`, `is_forum`, ` created_at` ,`updated_at`, `old_id`)
497497 VALUES
498- (:id, :type, :title, :username, :first_name, :last_name, :created_at, :updated_at, :old_id)
498+ (:id, :type, :title, :username, :first_name, :last_name, :is_forum, : created_at, :updated_at, :old_id)
499499 ON DUPLICATE KEY UPDATE
500500 `type` = VALUES(`type`),
501501 `title` = VALUES(`title`),
502502 `username` = VALUES(`username`),
503503 `first_name` = VALUES(`first_name`),
504504 `last_name` = VALUES(`last_name`),
505+ `is_forum` = VALUES(`is_forum`),
505506 `updated_at` = VALUES(`updated_at`)
506507 ' );
507508
@@ -523,6 +524,7 @@ public static function insertChat(Chat $chat, ?string $date = null, ?int $migrat
523524 $ sth ->bindValue (':username ' , $ chat ->getUsername ());
524525 $ sth ->bindValue (':first_name ' , $ chat ->getFirstName ());
525526 $ sth ->bindValue (':last_name ' , $ chat ->getLastName ());
527+ $ sth ->bindValue (':is_forum ' , $ chat ->getIsForum ());
526528 $ date = $ date ?: self ::getTimestamp ();
527529 $ sth ->bindValue (':created_at ' , $ date );
528530 $ sth ->bindValue (':updated_at ' , $ date );
0 commit comments