aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Group/database.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Group/database.php')
-rw-r--r--lib/Group/database.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/Group/database.php b/lib/Group/database.php
index c10f6db80e0..bdf5bbc5c55 100644
--- a/lib/Group/database.php
+++ b/lib/Group/database.php
@@ -37,7 +37,7 @@
*
*/
-oc_require_once( 'Group/backend.php' );
+require_once( 'Group/backend.php' );
/**
* Class for group management in a SQL Database (e.g. MySQL, SQLite)
@@ -75,7 +75,12 @@ class OC_GROUP_DATABASE extends OC_GROUP_BACKEND {
public static function inGroup( $username, $groupName ){
$query = OC_DB::prepare( "SELECT * FROM `*PREFIX*group_user` WHERE `gid` = ? AND `uid` = ?" );
$result = $query->execute( array( $groupName, $username ));
-
+ if( PEAR::isError($result)) {
+ $entry = 'DB Error: "'.$result->getMessage().'"<br />';
+ $entry .= 'Offending command was: '.$result->getDebugInfo().'<br />';
+ error_log( $entry );
+ die( $entry );
+ }
return $result->numRows() > 0 ? true : false;
}