ForceGroup and some qvitter API stuff still used staticGet

This commit is contained in:
Mikael Nordfeldth 2013-10-25 13:17:29 +02:00
parent 340740266c
commit 362b6ad2fc
4 changed files with 6 additions and 6 deletions

View File

@ -102,7 +102,7 @@ class ApiAccountRegisterAction extends ApiAction
} }
if (!empty($this->code)) { if (!empty($this->code)) {
$this->invite = Invitation::staticGet('code', $this->code); $this->invite = Invitation::getKV('code', $this->code);
if (empty($this->invite)) { if (empty($this->invite)) {
// TRANS: Client error displayed when trying to register to an invite-only site without a valid invitation. // TRANS: Client error displayed when trying to register to an invite-only site without a valid invitation.
$this->clientError(_('Sorry, invalid invitation code.'), 401); $this->clientError(_('Sorry, invalid invitation code.'), 401);
@ -197,7 +197,7 @@ class ApiAccountRegisterAction extends ApiAction
if (!$email || strlen($email) == 0) { if (!$email || strlen($email) == 0) {
return false; return false;
} }
$user = User::staticGet('email', $email); $user = User::getKV('email', $email);
return is_object($user); return is_object($user);
} }

View File

@ -53,7 +53,7 @@ class ApiExternalProfileShowAction extends ApiPrivateAuthAction
$profileurl = urldecode($this->arg('profileurl')); $profileurl = urldecode($this->arg('profileurl'));
// TODO: Make this more ... unique! // TODO: Make this more ... unique!
$this->profile = Profile::staticGet('profileurl', $profileurl); $this->profile = Profile::getKV('profileurl', $profileurl);
if (!($this->profile instanceof Profile)) { if (!($this->profile instanceof Profile)) {
// TRANS: Client error displayed when requesting profile information for a non-existing profile. // TRANS: Client error displayed when requesting profile information for a non-existing profile.

View File

@ -56,7 +56,7 @@ class ApiStatusesFavsAction extends ApiAuthAction
$id = $this->trimmed('id'); $id = $this->trimmed('id');
$this->original = Notice::staticGet('id', $id); $this->original = Notice::getKV('id', $id);
if (!($this->original instanceof Notice)) { if (!($this->original instanceof Notice)) {
// TRANS: Client error displayed trying to display redents of a non-exiting notice. // TRANS: Client error displayed trying to display redents of a non-exiting notice.
@ -102,7 +102,7 @@ class ApiStatusesFavsAction extends ApiAuthAction
$ids_with_profile_data = array(); $ids_with_profile_data = array();
$i=0; $i=0;
foreach($ids as $id) { foreach($ids as $id) {
$profile = Profile::staticGet('id', $id); $profile = Profile::getKV('id', $id);
$ids_with_profile_data[$i]['user_id'] = $id; $ids_with_profile_data[$i]['user_id'] = $id;
$ids_with_profile_data[$i]['nickname'] = $profile->nickname; $ids_with_profile_data[$i]['nickname'] = $profile->nickname;
$ids_with_profile_data[$i]['fullname'] = $profile->fullname; $ids_with_profile_data[$i]['fullname'] = $profile->fullname;

View File

@ -53,7 +53,7 @@ class ForceGroupPlugin extends Plugin
{ {
$profile = $notice->getProfile(); $profile = $notice->getProfile();
$isRemote = !(User::staticGet('id', $profile->id)); $isRemote = !(User::getKV('id', $profile->id));
if ($isRemote) { if ($isRemote) {
/* /*
* Notices from remote users on other sites * Notices from remote users on other sites