oc_db is not pdo

also pgsql does not like double quotes
This commit is contained in:
Robin Appelman 2012-04-01 17:31:44 +02:00
parent b758725bf7
commit 39e8981bc2
1 changed files with 4 additions and 4 deletions

View File

@ -103,9 +103,9 @@ class OC_App{
*/
public static function getEnabledApps(){
$apps=array();
$query = OC_DB::prepare( 'SELECT appid FROM *PREFIX*appconfig WHERE configkey = "enabled" AND configvalue="yes"' );
$query->execute();
while($row=$query->fetchRow()){
$query = OC_DB::prepare( 'SELECT appid FROM *PREFIX*appconfig WHERE configkey = \'enabled\' AND configvalue=\'yes\'' );
$result=$query->execute();
while($row=$result->fetchRow()){
$apps[]=$row['appid'];
}
return $apps;
@ -452,7 +452,7 @@ class OC_App{
*/
public static function getAppVersions(){
$versions=array();
$query = OC_DB::prepare( 'SELECT appid, configvalue FROM *PREFIX*appconfig WHERE configkey = "installed_version"' );
$query = OC_DB::prepare( 'SELECT appid, configvalue FROM *PREFIX*appconfig WHERE configkey = \'installed_version\'' );
$result = $query->execute();
while($row = $result->fetchRow()){
$versions[$row['appid']]=$row['configvalue'];