summaryrefslogtreecommitdiff
path: root/app/models/concerns/avatarable.rb
Commit message (Collapse)AuthorAgeFilesLines
* Fix an N+1 in avatar URLsSean McGivern2018-06-051-0/+47
| | | | | | | | | | | | | | | | This is tricky: the query was being run in `ObjectStorage::Extension::RecordsUploads#retrieve_from_store!`, but we can't just add batch loading there, because the `#upload=` method there would use the result immediately, making the batch only have one item. Instead, we can pre-emptively add an item to the batch whenever an avatarable object is initialized, and then reuse that batch item in `#retrieve_from_store!`. However, this also has problems: 1. There is a lot of logic in `Avatarable#retrieve_upload_from_batch`. 2. Some of that logic constructs a 'fake' model for the batch key. This should be fine, because of ActiveRecord's override of `#==`, but it relies on that staying the same.
* Resolve "Avatar URLs are wrong when using a CDN path and Object Storage"Micaël Bergeron2018-04-231-2/+3
|
* Merge branch '40781-os-to-ce' into 'master'Sean McGivern2018-03-271-0/+1
|\ | | | | | | | | | | | | Bring Object Storage to CE Closes #4171, #4163, #3370, #2841, and #29203 See merge request gitlab-org/gitlab-ce!17358
| * port the object storage to CEMicaël Bergeron2018-03-011-0/+1
| |
| * Merge branch '4163-move-uploads-to-object-storage' into 'master'Sean McGivern2018-02-281-0/+24
| | | | | | | | | | | | | | | | Move uploads to object storage Closes #4163 See merge request gitlab-org/gitlab-ee!3867
* | Change avatar error message to include allowed file formatsFabian Schneider2018-03-221-1/+1
| |
* | port of 594e6a0a625^..f74c90f68c6Micaël Bergeron2018-02-011-0/+24
|/
* Always return full avatar URL for private/internal groups/projects when ↵Douwe Maan2017-11-091-7/+18
| | | | asset host is set
* Based on MR simplified the logicTim Zallmann2017-10-091-2/+2
|
* Updates based on MR commentsTim Zallmann2017-10-051-5/+3
|
* Fixed Linting errors + testsTim Zallmann2017-10-041-4/+2
|
* Created group_icon and group_icon_urlTim Zallmann2017-10-041-1/+1
| | | | Tests for these new helper methods
* Making private project avatars use local paths + Some Group IconsTim Zallmann2017-10-041-5/+9
|
* Use relative paths for group/project/user avatarsblackst0ne2017-05-101-0/+18