From 94fb9c240661a9cd2b7199a648e9c5b4f9b69e8d Mon Sep 17 00:00:00 2001 From: Christian Vogeley Date: Sun, 8 Sep 2013 00:21:42 +0200 Subject: Service class identity, follow, photo upload, att upload --- include/identity.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'include/identity.php') diff --git a/include/identity.php b/include/identity.php index 8db6355c0..98209c8ae 100644 --- a/include/identity.php +++ b/include/identity.php @@ -7,7 +7,7 @@ require_once('include/crypto.php'); function identity_check_service_class($account_id) { $ret = array('success' => false, $message => ''); - $r = q("select count(channel_id) as total from channel were channel_account_id = %d ", + $r = q("select count(channel_id) as total from channel where channel_account_id = %d ", intval($account_id) ); if(! ($r && count($r))) { @@ -80,7 +80,10 @@ function create_identity($arr) { $ret['message'] = t('No account identifier'); return $ret; } - + $ret=identity_check_service_class($arr['account_id']); + if (!$ret['success']) { + return $ret; + } $nick = mb_strtolower(trim($arr['nickname'])); $name = escape_tags($arr['name']); $pageflags = ((x($arr,'pageflags')) ? intval($arr['pageflags']) : PAGE_NORMAL); -- cgit v1.2.3