diff --git a/pkg/controller/photo/view.go b/pkg/controller/photo/view.go index a50cf4a..60df70e 100644 --- a/pkg/controller/photo/view.go +++ b/pkg/controller/photo/view.go @@ -55,6 +55,12 @@ func View() http.HandlerFunc { return } + // Is this a circle photo? + if photo.Visibility == models.PhotoInnerCircle && !currentUser.IsInnerCircle() { + templates.NotFoundPage(w, r) + return + } + // Is this user private and we're not friends? var ( areFriends = models.AreFriends(user.ID, currentUser.ID)