mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-08 10:34:34 +00:00
Fix sql to get created client apps
This commit is contained in:
@@ -704,8 +704,9 @@ class API_OAuth2_Application
|
|||||||
public static function load_dev_app_by_user(Application $app, User_Adapter $user)
|
public static function load_dev_app_by_user(Application $app, User_Adapter $user)
|
||||||
{
|
{
|
||||||
$sql = 'SELECT a.application_id
|
$sql = 'SELECT a.application_id
|
||||||
FROM api_applications a, api_accounts b
|
FROM api_applications a
|
||||||
WHERE a.creator = :usr_id AND a.application_id = b.application_id';
|
INNER JOIN api_accounts b ON a.application_id = b.application_id
|
||||||
|
WHERE a.creator = :usr_id AND b.usr_id = :usr_id';
|
||||||
|
|
||||||
$stmt = $app['phraseanet.appbox']->get_connection()->prepare($sql);
|
$stmt = $app['phraseanet.appbox']->get_connection()->prepare($sql);
|
||||||
$stmt->execute(array(':usr_id' => $user->get_id()));
|
$stmt->execute(array(':usr_id' => $user->get_id()));
|
||||||
|
Reference in New Issue
Block a user