Skip to content

Commit d48702f

Browse files
authored
fix(mobile): Showing videos of partner in search page quick links (#18855)
Add userId to the contact of the timeline interface method watchAllVideosTimeline and modify the query in the repository
1 parent fa22e86 commit d48702f

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

mobile/lib/interfaces/timeline.interface.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ abstract class ITimelineRepository {
1414
Album album,
1515
GroupAssetsBy groupAssetsBy,
1616
);
17-
Stream<RenderList> watchAllVideosTimeline();
17+
Stream<RenderList> watchAllVideosTimeline(String userId);
1818

1919
Stream<RenderList> watchHomeTimeline(
2020
String userId,

mobile/lib/repositories/timeline.repository.dart

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,10 @@ class TimelineRepository extends DatabaseRepository
9898
}
9999

100100
@override
101-
Stream<RenderList> watchAllVideosTimeline() {
101+
Stream<RenderList> watchAllVideosTimeline(String userId) {
102102
final query = db.assets
103+
.where()
104+
.ownerIdEqualToAnyChecksum(fastHash(userId))
103105
.filter()
104106
.isTrashedEqualTo(false)
105107
.visibilityEqualTo(AssetVisibilityEnum.timeline)

mobile/lib/services/timeline.service.dart

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,9 @@ class TimelineService {
7575
}
7676

7777
Stream<RenderList> watchAllVideosTimeline() {
78-
return _timelineRepository.watchAllVideosTimeline();
78+
final user = _userService.getMyUser();
79+
80+
return _timelineRepository.watchAllVideosTimeline(user.id);
7981
}
8082

8183
Future<RenderList> getTimelineFromAssets(

0 commit comments

Comments
 (0)