diff options
author | Wave <wave72@users.noreply.github.com> | 2016-07-22 10:55:02 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-07-22 10:55:02 +0200 |
commit | 744ad84714fe0f7a3d90250a4ff02dc4327b9061 (patch) | |
tree | 595fb74ec9ea0bc7130d18bd7993d719a222d343 /util/fresh | |
parent | c38c79d71c8ef70ef649f83e322f1984b75ee2dd (diff) | |
parent | 7d897a3f03bd57ed556433eb84a41963ba44e02e (diff) | |
download | volse-hubzilla-744ad84714fe0f7a3d90250a4ff02dc4327b9061.tar.gz volse-hubzilla-744ad84714fe0f7a3d90250a4ff02dc4327b9061.tar.bz2 volse-hubzilla-744ad84714fe0f7a3d90250a4ff02dc4327b9061.zip |
Merge pull request #6 from redmatrix/dev
Dev
Diffstat (limited to 'util/fresh')
-rwxr-xr-x | util/fresh | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/util/fresh b/util/fresh index c70f1cac9..7f57931aa 100755 --- a/util/fresh +++ b/util/fresh @@ -68,9 +68,9 @@ function process_command($line) { case 'finger': if(argv(1)) { - $x = zot_finger(argv(1),$channel); + $x = Zotlabs\Zot\Finger::run(argv(1),$channel); if($x['success']) - echo jindent($x['body']); + echo jindent($x); } break; @@ -82,12 +82,15 @@ function process_command($line) { exec('/bin/stty echo'); echo "\n"; require_once('include/auth.php'); - $record = App::$account = account_verify_password(argv(1),trim($x,"\n")); + $record = null; + $x = account_verify_password(argv(1),trim($x,"\n")); + if($x['account']) + $record = App::$account = $x['account']; if($record) { $_SESSION['account_id'] = App::$account['account_id']; $_SESSION['last_login_date'] = datetime_convert(); - authenticate_success($record, true, true); + authenticate_success($record, $x['channel'], true, true); echo 'logged in'; $channel = App::get_channel(); if($channel) |