multiGet instead of listFind, subs now in order!

It was desired that subscriptions were listed in an order
with the latest first.
This commit is contained in:
Mikael Nordfeldth 2014-10-25 17:57:20 +02:00
parent 694b370b20
commit 7589e78817

View File

@ -305,7 +305,7 @@ class Profile extends Managed_DataObject
} }
try { try {
return User_group::listFind('id', $ids); return User_group::multiGet('id', $ids);
} catch (NoResultException $e) { } catch (NoResultException $e) {
return null; // throw exception when we handle it everywhere return null; // throw exception when we handle it everywhere
} }
@ -593,7 +593,7 @@ class Profile extends Managed_DataObject
{ {
$subs = Subscription::getSubscribedIDs($this->id, $offset, $limit); $subs = Subscription::getSubscribedIDs($this->id, $offset, $limit);
try { try {
$profiles = Profile::listFind('id', $subs); $profiles = Profile::multiGet('id', $subs);
} catch (NoResultException $e) { } catch (NoResultException $e) {
return $e->obj; return $e->obj;
} }
@ -604,7 +604,7 @@ class Profile extends Managed_DataObject
{ {
$subs = Subscription::getSubscriberIDs($this->id, $offset, $limit); $subs = Subscription::getSubscriberIDs($this->id, $offset, $limit);
try { try {
$profiles = Profile::listFind('id', $subs); $profiles = Profile::multiGet('id', $subs);
} catch (NoResultException $e) { } catch (NoResultException $e) {
return $e->obj; return $e->obj;
} }