mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-20 22:26:54 +01:00
return null, not empty list, when nothing found
This commit is contained in:
parent
f31e28dbd7
commit
994a73e28b
1 changed files with 6 additions and 1 deletions
|
@ -180,6 +180,7 @@ public class DBUtils {
|
||||||
|
|
||||||
public static String[] getRelayIDNoMsgs( Context context )
|
public static String[] getRelayIDNoMsgs( Context context )
|
||||||
{
|
{
|
||||||
|
String[] result = null;
|
||||||
initDB( context );
|
initDB( context );
|
||||||
ArrayList<String> ids = new ArrayList<String>();
|
ArrayList<String> ids = new ArrayList<String>();
|
||||||
|
|
||||||
|
@ -207,7 +208,11 @@ public class DBUtils {
|
||||||
cursor.close();
|
cursor.close();
|
||||||
db.close();
|
db.close();
|
||||||
}
|
}
|
||||||
return ids.toArray( new String[ids.size()] );
|
|
||||||
|
if ( 0 < ids.size() ) {
|
||||||
|
result = ids.toArray( new String[ids.size()] );
|
||||||
|
}
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void initDB( Context context )
|
private static void initDB( Context context )
|
||||||
|
|
Loading…
Reference in a new issue