We are no longer offering accounts on this server. Consider https://gitlab.freedesktop.org/ as a place to host projects.

Commit b1802b87 authored by Evan Prodromou's avatar Evan Prodromou

don't redeclare getUser() for backupuser.php

parent 670ad532
......@@ -34,30 +34,6 @@ END_OF_EXPORTACTIVITYSTREAM_HELP;
require_once INSTALLDIR.'/scripts/commandline.inc';
function getUser()
{
$user = null;
if (have_option('i', 'id')) {
$id = get_option_value('i', 'id');
$user = User::staticGet('id', $id);
if (empty($user)) {
throw new Exception("Can't find user with id '$id'.");
}
} else if (have_option('n', 'nickname')) {
$nickname = get_option_value('n', 'nickname');
$user = User::staticGet('nickname', $nickname);
if (empty($user)) {
throw new Exception("Can't find user with nickname '$nickname'");
}
} else {
show_help();
exit(1);
}
return $user;
}
try {
$user = getUser();
$actstr = new UserActivityStream($user);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment