Server returns location of lychee

Used for the new server-import dialog
This commit is contained in:
Tobias Reich 2014-07-23 21:24:25 +02:00
parent 864b317e4c
commit 653511e6c6
2 changed files with 6 additions and 0 deletions

View File

@ -23,6 +23,7 @@ var lychee = {
username: "",
checkForUpdates: false,
sorting: "",
location: "",
dropbox: false,
dropboxKey: '',
@ -46,6 +47,7 @@ var lychee = {
lychee.username = data.config.username || '';
lychee.sorting = data.config.sorting || '';
lychee.dropboxKey = data.config.dropboxKey || '';
lychee.location = data.config.location || '';
}
// No configuration

View File

@ -42,6 +42,9 @@ class Session extends Module {
$return['config'] = $this->settings;
unset($return['config']['password']);
# Path to Lychee for the server-import dialog
$return['config']['location'] = LYCHEE;
# No login
if ($this->settings['username']===''&&$this->settings['password']==='') $return['config']['login'] = false;
else $return['config']['login'] = true;
@ -59,6 +62,7 @@ class Session extends Module {
unset($return['config']['sorting']);
unset($return['config']['dropboxKey']);
unset($return['config']['login']);
unset($return['config']['location']);
# Logged out
$return['loggedIn'] = false;