migrated and improved two functions regarding PDO stuff, refs #1287
Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>
This commit is contained in:
@@ -29,8 +29,7 @@ function domainHasMainSubDomains($id = 0) {
|
||||
SELECT COUNT(`id`) as `mainsubs` FROM `".TABLE_PANEL_DOMAINS."`
|
||||
WHERE `ismainbutsubto` = :id"
|
||||
);
|
||||
Database::pexecute($result_stmt, array('id' => $id));
|
||||
$result = $result_stmt->fetch(PDO::FETCH_ASSOC);
|
||||
$result = Database::pexecute_first($result_stmt, array('id' => $id));
|
||||
|
||||
if (isset($result['mainsubs'])
|
||||
&& $result['mainsubs'] > 0
|
||||
|
||||
Reference in New Issue
Block a user