mirror of
https://github.com/immich-app/immich.git
synced 2025-08-11 09:16:31 -04:00
limit getAll to 250 lines
This commit is contained in:
parent
7523fc2521
commit
76dc2ad181
@ -28,8 +28,10 @@ class LogRepository {
|
||||
return true;
|
||||
}
|
||||
|
||||
Future<List<LogMessage>> getAll() async {
|
||||
final query = _db.logMessageEntity.select()..orderBy([(row) => OrderingTerm.desc(row.createdAt)]);
|
||||
Future<List<LogMessage>> getAll({int limit = 250}) async {
|
||||
final query = _db.logMessageEntity.select()
|
||||
..orderBy([(row) => OrderingTerm.desc(row.createdAt)])
|
||||
..limit(limit);
|
||||
|
||||
return query.map((log) => log.toDto()).get();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user