Skip to content

Commit

Permalink
also let immich admin access all photos
Browse files Browse the repository at this point in the history
  • Loading branch information
pontussjostedt committed Feb 17, 2025
1 parent a9dcbb7 commit b662085
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/src/repositories/album.repository.ts
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ export class AlbumRepository implements IAlbumRepository {
//This should only be called by an eguild admin
@GenerateSql({ params: [DummyValue.UUID] })
async getAll(auth: AuthDto): Promise<AlbumEntity[]> {
if (!(auth.features.includes('superadmin') || auth.features.includes('emmech_admin'))) {
if (!(auth.features.includes('superadmin') || auth.features.includes('emmech_admin') || auth.user.isAdmin)) {
return [];
}
const albums = await this.repository.find({
Expand Down

0 comments on commit b662085

Please sign in to comment.