Refactor the detection of the case when no database has been selected. re #127
This commit is contained in:
parent
8a3cc9ed5c
commit
a1cb83eea9
4 changed files with 12 additions and 11 deletions
|
@ -33,7 +33,7 @@
|
|||
|
||||
// Access the database ASAP to be sure it's readable, redirect if that's not the case.
|
||||
// It has to be done before any header is sent.
|
||||
if (is_array ($config['calibre_directory']) && is_null ($database)) {
|
||||
if (Base::noDatabaseSelected ()) {
|
||||
$i = 0;
|
||||
foreach (array_keys ($config['calibre_directory']) as $key) {
|
||||
$test = Base::getDb ($i);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue