Index: trunk/phase3/maintenance/archives/patch-user-newtalk-timestamp-null.sql |
— | — | @@ -0,0 +1 @@ |
| 2 | +ALTER TABLE /*_*/user_newtalk MODIFY user_last_timestamp varbinary(14) NULL default NULL; |
Property changes on: trunk/phase3/maintenance/archives/patch-user-newtalk-timestamp-null.sql |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 3 | + native |
Index: trunk/phase3/includes/installer/MysqlUpdater.php |
— | — | @@ -176,6 +176,9 @@ |
177 | 177 | array( 'addIndex', 'archive', 'ar_revid', 'patch-archive_ar_revid.sql' ), |
178 | 178 | array( 'doLangLinksLengthUpdate' ), |
179 | 179 | array( 'doClTypeVarcharUpdate' ), |
| 180 | + |
| 181 | + // 1.18 |
| 182 | + array( 'doUserNewTalkTimestampNotNull' ), |
180 | 183 | ); |
181 | 184 | } |
182 | 185 | |
— | — | @@ -843,4 +846,16 @@ |
844 | 847 | $this->output( "...cl_type is up-to-date.\n" ); |
845 | 848 | } |
846 | 849 | } |
| 850 | + |
| 851 | + protected function doUserNewTalkTimestampNotNull() { |
| 852 | + $info = $this->db->fieldInfo( 'user_newtalk', 'user_last_timestamp' ); |
| 853 | + if ( $info->isNullable() ) { |
| 854 | + $this->output( "...user_last_timestamp is already nullable.\n" ); |
| 855 | + return; |
| 856 | + } |
| 857 | + |
| 858 | + $this->output( "Making user_last_timestamp nullable... " ); |
| 859 | + $this->applyPatch( 'patch-user-newtalk-timestamp-null.sql' ); |
| 860 | + $this->output( "done.\n" ); |
| 861 | + } |
847 | 862 | } |