diff options
| author | 2016-10-24 20:29:08 +0200 | |
|---|---|---|
| committer | 2016-10-24 20:29:08 +0200 | |
| commit | 1182129ce5f07892afed190ffbb2ea4c7fc28967 (patch) | |
| tree | 969df97e334667b9e76d9b0a387486959b1da700 /app/install.php | |
| parent | 879af85d3ce1223cc5642e9beb6ec05d1097e43a (diff) | |
CLI option no-default-feeds
https://github.com/FreshRSS/FreshRSS/issues/1095
Diffstat (limited to 'app/install.php')
| -rw-r--r-- | app/install.php | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/app/install.php b/app/install.php index 6956761c7..0daa02b1b 100644 --- a/app/install.php +++ b/app/install.php @@ -357,6 +357,21 @@ function checkDbUser(&$dbOptions) { } } } + + if (defined('SQL_INSERT_FEEDS')) { + $sql = sprintf(SQL_INSERT_FEEDS, $dbOptions['bd_prefix_user']); + $stm = $c->prepare($sql); + $ok &= $stm->execute(); + } else { + global $SQL_INSERT_FEEDS; + if (is_array($SQL_INSERT_FEEDS)) { + foreach ($SQL_INSERT_FEEDS as $instruction) { + $sql = sprintf($instruction, $dbOptions['bd_prefix_user']); + $stm = $c->prepare($sql); + $ok &= $stm->execute(); + } + } + } } catch (PDOException $e) { $ok = false; $dbOptions['bd_error'] = $e->getMessage(); |
