mirror of
https://github.com/signalapp/Signal-Android.git
synced 2025-12-22 20:18:36 +00:00
Convert ThreadDatabase to kotlin.
This commit is contained in:
committed by
Alex Hart
parent
d2b72fc8b7
commit
1e88fb428d
@@ -104,12 +104,4 @@ public final class CursorUtil {
|
||||
|
||||
return row.toString();
|
||||
}
|
||||
|
||||
public static @Nullable <T> T getAggregateOrDefault(@NonNull Cursor cursor, @Nullable T defaultValue, @NonNull Function<Integer, T> cursorColumnFn) {
|
||||
if (cursor.moveToFirst()) {
|
||||
return cursorColumnFn.apply(0);
|
||||
} else {
|
||||
return defaultValue;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user