diff --git a/include/class.config.php b/include/class.config.php index 8b7dde5d8542e1e59f35bffd6a7c8021041579cc..61b5012dfb1b6309fec706a0f457a917e6297185 100644 --- a/include/class.config.php +++ b/include/class.config.php @@ -150,8 +150,19 @@ extends VerySimpleModel { ); static function items($namespace, $column='namespace') { - return static::objects() + + $items = static::objects() ->filter([$column => $namespace]); + + try { + count($items); + } + catch (InconsistentModelException $ex) { + // Pending upgrade ?? + $items = array(); + } + + return $items; } function save($refetch=false) {