Commit graph

92 commits

Author SHA1 Message Date
Johannes Wilm
a977753b2c lint and add pre-commit configuration 2022-08-09 21:17:24 +02:00
Johannes Wilm
6ba1280a7e remove six 2022-07-16 23:25:43 +02:00
Johannes Wilm
8f94d125b3 switch to github actions 2022-07-16 23:02:49 +02:00
Johannes Wilm
ae950c9b50 black 2022-07-16 22:50:05 +02:00
Johannes Wilm
a131861589 Merge branch 'django4.0' of github.com:johanneswilm/django-avatar 2022-07-16 22:27:50 +02:00
Johannes Wilm
03c95bc925 update imports 2022-07-16 22:26:58 +02:00
Nicholas H.Tollervey
68340e8ac6
Update to work with Django 4.0. Based upon PR #201. 2022-01-27 18:41:45 +00:00
Johannes Wilm
53b7fa2265
use original file as default
If thumbnail creation fails but the original files could be read, save the original file as the thumbnail.
2020-03-02 18:47:00 +01:00
Grant McConnaughey
ce56f6a104
Merge pull request #177 from rafiqhilali/avatar-deletion-storage-bug
Avatar storage deletion bug
2020-01-04 11:41:27 -06:00
bastb
2793ff0830 Fixes the Django 3.0 six issue 2019-12-03 08:16:14 +01:00
Rafiq Hilali
15879af5ce fixed storage deletion bug 2019-02-11 17:12:11 +00:00
Ricardo Garcia Silva
a26a133d9d
use the lazy version of gettext for translating models 2018-07-02 12:08:00 +01:00
Grant McConnaughey
2de2a60e85 Fix conflicts 2017-12-17 10:24:02 -06:00
Clement Cavanier
69901569a3 Support for Django 2 2017-12-06 15:06:45 +01:00
Grant McConnaughey
f8716937b0 Prevented creation of the new migrations with non-default DEFAULT_FILE_STORAGE 2017-08-27 08:45:45 -05:00
Arne Holzenburg
341732a38c Transpose based on EXIF orientation
Transpose the original image before resizing based on EXIF orientation
information to display image in the correct orientation. If someone
uploads an image from an iPhone (for example) the image is currently
often rendered in the wrong orientation.
2017-07-11 14:42:55 +02:00
Jannis
6091dd90fe Add blank line to resolve failing PEP8 check. 2017-05-27 09:50:47 -05:00
Jannis
112141a457 Add verbose_names to Avatar model. 2016-09-16 10:55:13 +02:00
Grant McConnaughey
5cbd095cda Rename util -> utils, fix URL issue 2016-02-09 09:42:29 -06:00
Grant McConnaughey
a6b4c2beea Merge pull request #75 from z4r/patch-1
Preserve RGBA image.mode
2016-02-09 09:17:52 -06:00
Grant McConnaughey
c2a5cec2bf Added documentation for new settings 2016-02-09 09:06:16 -06:00
Grant McConnaughey
b10197ac5a Merge pull request #105 from barbuza/master
`EXPOSE_USERNAMES` prevents sensitive information leakage
2016-02-09 08:46:17 -06:00
Kaspars Sprogis
cdb7974054 New setting to specify path to a method for avatar file path
handling. Solves problems related to custom deployments and
directory paths: #10 #9.
2016-02-08 22:01:12 +02:00
Victor Kotseruba
0aaa59e0a7 RANDOMIZE_HASHES option 2016-01-18 18:57:41 +08:00
Grant McConnaughey
a258377207 Revert unique user/primary pair 2015-10-23 09:33:10 -05:00
Danny Browne
1c56ed5dbc added database-level enforcement of unique user+primary pair in Avatar model 2015-09-04 12:58:32 -04:00
Kaloian Minkov
97b1ffd020 Add Django 1.8+ style Meta app_label to Avatar model to prevent RemovedInDjango19Warning 2015-07-23 11:23:33 +03:00
Victor Kotseruba
1197dbe739 EXPOSE_USERNAMES prevents sensitive information leakage 2015-06-12 01:33:20 +03:00
Andrea de Marco
c1f278bb84 Preserve RGBA image.mode 2014-01-10 10:35:07 +01:00
Jannis Leidel
65d5f66b9b Use django-appconf for nicer settings handling. 2013-09-13 17:59:52 +02:00
Jannis Leidel
49148f1d70 Reduce repetition. 2013-09-13 17:24:02 +02:00
andrean
6c9b44e2e7 fix create_thumbnail saving for images not requiring resize 2013-08-14 16:18:52 +02:00
Jannis Leidel
2131c79441 Use PIL.Image. 2013-08-01 14:48:43 +02:00
Jannis Leidel
b12bb9f193 Use str just in case. 2013-08-01 14:35:59 +02:00
Jannis Leidel
7a32e3bd47 More Python 3 fixes. 2013-08-01 14:32:03 +02:00
Jannis Leidel
05ef51078f Use integer sizes. 2013-08-01 14:11:59 +02:00
Jannis Leidel
29570b1a1b Use storage file directly. 2013-08-01 14:09:04 +02:00
Jannis Leidel
fc98737ce3 Use six.StringIO. 2013-08-01 13:29:19 +02:00
Jannis Leidel
a47e2e2811 Fixed some Python 3 bug. 2013-08-01 13:19:56 +02:00
Jannis Leidel
57d77caeb0 Revamped tests and added Travis config. 2013-08-01 13:12:49 +02:00
Jannis Leidel
b8844d8cd9 Merge branch 'master' of git://github.com/DrMeers/django-avatar into DrMeers-master
Conflicts:
	avatar/models.py
2013-05-27 10:13:16 +02:00
Brendon Crawford
8627f67046 Replace Django Hashcompat with Hashlib 2013-03-22 13:55:28 -07:00
Simon Meers
7ee83431b3 More quickly scrawled / untested custom user model support changes 2013-03-15 21:45:24 +11:00
Simon Meers
93fb42fd83 Commence experimental support for custom User models. 2013-03-15 21:29:07 +11:00
Mathieu Pillard
aac26b8c70 Add a get_absolute_url() method to help implementors (it needs to exists for projects to overwrite it)
Conflicts:
	avatar/models.py
2013-03-04 12:32:48 +01:00
Jannis Leidel
68731b6bc6 Merge remote-tracking branch 'chadpaulson/master'
Conflicts:
	MANIFEST.in
	avatar/models.py
	avatar/settings.py
	avatar/templatetags/avatar_tags.py
	avatar/views.py
	setup.py
2013-03-04 11:43:23 +01:00
Chad Paulson
b5937382ab Added post_delete signal to Avatar model in order to clean up the file system when AVATAR_MAX_AVATARS_PER_USER is equal to 1 or when Avatar instances are removed. This functionality is controlled by the new AVATAR_CLEAN_REMOVED setting which is False by default. 2013-01-18 19:39:31 -06:00
Jannis Leidel
264c83671a Fixed invalidating the avatar cache by making it happen post_save and post_delete. 2012-10-05 15:52:02 +02:00
Jannis Leidel
2650cf0282 Minor syntax cleanup. 2012-10-05 12:07:47 +02:00
Jannis Leidel
c8bf40ebe3 Catch IOError in the rest of the create_thumbnail method, too, to work around an issue with Django>1.4.1 which verifies the images being saved. 2012-10-05 12:07:13 +02:00