if ((isExtensionInstalledAndNewer('sql_patches', '0.3.4')) && (isExtensionActive('user'))) {
// Check for accounts without referal
- addSql("SELECT `userid` FROM `{?_MYSQL_PREFIX?}_user_data` WHERE `refid`=0 ORDER BY `userid` ASC");
+ addSql("SELECT `userid` FROM `{?_MYSQL_PREFIX?}_user_data` WHERE `refid`=0 OR `refid` IS NULL ORDER BY `userid` ASC");
$DESCRs[] = '{--ADMIN_TASK_LIST_ACCOUNT_NOREF--}';
$TITLEs[] = '{--ADMIN_TASK_LIST_ACCOUNT_NOREFERAL_TITLE--}';
$WHATs[] = 'list_user&mode=norefs';