Skip to content
This repository has been archived by the owner on Apr 12, 2021. It is now read-only.

Commit

Permalink
feat(repositories): #1533 repositories will show in descending order …
Browse files Browse the repository at this point in the history
…by updated on
  • Loading branch information
webkhushboo committed Sep 25, 2019
1 parent 148f08e commit 5d5c3c5
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion web/src/app/core/services/repository.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,11 @@ export class RepositoryService {
return this.activityService
.start()
.pipe(
switchMap(() => this.afs.collection<IRepository>('repositories').doc<IRepository>(uid).valueChanges()),
switchMap(() => this.afs.collection<IRepository>(
'repositories',
(ref: firebase.firestore.Query) => ref
.orderBy('updatedOn', 'desc')
).doc<IRepository>(uid).valueChanges()),
map((repository: IRepository) => new RepositoryModel(repository))
);
}
Expand Down

0 comments on commit 5d5c3c5

Please sign in to comment.