fix for federating profile pictures [ci skip]
This commit is contained in:
parent
fc65d0fea2
commit
b2e9e47b38
1 changed files with 4 additions and 3 deletions
|
|
@ -146,14 +146,15 @@ class StatusMessage < Post
|
||||||
end
|
end
|
||||||
|
|
||||||
def update_and_dispatch_attached_photos(sender)
|
def update_and_dispatch_attached_photos(sender)
|
||||||
unless self.photos.empty?
|
if self.photos.any?
|
||||||
self.photos.update_all(:pending => false, :public => self.public)
|
self.photos.update_all(:public => self.public)
|
||||||
for photo in self.photos
|
self.photos.each do |photo|
|
||||||
if photo.pending
|
if photo.pending
|
||||||
sender.add_to_streams(photo, self.aspects)
|
sender.add_to_streams(photo, self.aspects)
|
||||||
sender.dispatch_post(photo)
|
sender.dispatch_post(photo)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
self.photos.update_all(:pending => false)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue