* @return Revision|null Revision or null on error
*/
public static function newNullRevision( $dbw, $pageId, $summary, $minor, $user = null ) {
- global $wgContentHandlerUseDB;
+ global $wgContentHandlerUseDB, $wgContLang;
$fields = array( 'page_latest', 'page_namespace', 'page_title',
'rev_text_id', 'rev_len', 'rev_sha1' );
$user = $wgUser;
}
+ // Truncate for whole multibyte characters
+ $summary = $wgContLang->truncate( $summary, 255 );
+
$row = array(
'page' => $pageId,
'user_text' => $user->getName(),