create an index on user.created so sitemap generation is faster

This commit is contained in:
Evan Prodromou 2010-07-05 14:12:14 -04:00
parent c5e89527d9
commit 7746611f20

View File

@ -202,6 +202,12 @@ class SitemapPlugin extends Plugin
null, false),
new ColumnDef('modified', 'timestamp')));
$userCreated = $schema->getColumnDef('user', 'created');
if (empty($userCreated) || $userCreated->key != 'MUL') {
$schema->createIndex('user', 'created');
}
return true;
}