MDL-25031 ignore invalid block instances

pagetypepattern can not be null, so we ignore these until we find a way to fix them properly, sorry
This commit is contained in:
Petr Skoda 2010-11-08 03:28:54 +00:00
parent f38325960e
commit b871436148

View file

@ -1855,7 +1855,9 @@ WHERE gradeitemid IS NOT NULL AND grademax IS NOT NULL");
CASE WHEN subpagepattern IS NULL THEN ''
ELSE subpagepattern END,
0, defaultregion, defaultweight
FROM {block_instances} WHERE visible = 0 AND pagetypepattern <> 'admin-*'");
FROM {block_instances} WHERE visible = 0 AND pagetypepattern <> 'admin-*' AND pagetypepattern IS NOT NULL");
// note: MDL-25031 all block instances should have a pagetype pattern, NULL is not allowed,
// if we manage to find out how NULLs get there we should fix them before this step
/// Main savepoint reached
upgrade_main_savepoint(true, 2009050618);