Allow profile pictures from contacts
This commit is contained in:
parent
cf11713d9c
commit
23308d7e8c
|
@ -1359,7 +1359,10 @@ func (m *Messenger) HandleChatIdentity(state *ReceivedMessageState, ci protobuf.
|
|||
|
||||
// If we don't want to view profile images from anyone, don't process identity images.
|
||||
// We don't want to store the profile images of other users, even if we don't display images.
|
||||
if viewFromNoOne {
|
||||
inOurContacts, ok := m.allContacts.Load(state.CurrentMessageState.Contact.ID)
|
||||
|
||||
isContact := ok && inOurContacts.Added
|
||||
if viewFromNoOne && !isContact {
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
|
@ -512,7 +512,8 @@ func resultExpectedVS(vs accounts.ProfilePicturesVisibilityType, bc bool) (bool,
|
|||
case accounts.ProfilePicturesVisibilityEveryone:
|
||||
return true, nil
|
||||
case accounts.ProfilePicturesVisibilityNone:
|
||||
return false, nil
|
||||
// If we are contacts, we save the image regardless
|
||||
return bc, nil
|
||||
default:
|
||||
return false, errors.New("unknown ProfilePicturesVisibilityType")
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue