mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-10-04 07:09:58 +00:00
Cleanup code
This commit is contained in:
parent
1ec7bdf1f6
commit
b0b9ad2172
58 changed files with 310 additions and 424 deletions
|
@ -114,10 +114,8 @@ namespace LBPUnion.ProjectLighthouse.Controllers
|
|||
if (userFromQuery == null) return this.NotFound();
|
||||
|
||||
List<Photo> photos = new();
|
||||
foreach (Photo photo in this.database.Photos.Include(p => p.Creator))
|
||||
{
|
||||
photos.AddRange(photo.Subjects.Where(subject => subject.User.UserId == userFromQuery.UserId).Select(_ => photo));
|
||||
}
|
||||
foreach (Photo photo in this.database.Photos.Include
|
||||
(p => p.Creator)) photos.AddRange(photo.Subjects.Where(subject => subject.User.UserId == userFromQuery.UserId).Select(_ => photo));
|
||||
|
||||
string response = photos.OrderByDescending
|
||||
(s => s.Timestamp)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue