Version Description
- Fixed: Do not delete avatars just because they don't exist on the local filesystem. This was occasionally dumping avatars when WordPress uploads were stored elsewhere, e.g. a cloud service.
Download this release
Release Info
Developer | 10upbot |
Plugin | Simple Local Avatars |
Version | 2.1.1 |
Comparing to | |
See all releases |
Code changes from version 2.1 to 2.1.1
- readme.txt +6 -3
- screenshot-1.png +0 -0
- simple-local-avatars.php +1 -5
readme.txt
CHANGED
@@ -3,8 +3,8 @@ Contributors: jakemgold, 10up, thinkoomph
|
|
3 |
Donate link: https://10up.com/plugins/simple-local-avatars-wordpress/
|
4 |
Tags: avatar, gravatar, user photos, users, profile
|
5 |
Requires at least: 4.6
|
6 |
-
Tested up to:
|
7 |
-
Stable tag: 2.1
|
8 |
Text Domain: simple-local-avatars
|
9 |
|
10 |
Adds an avatar upload field to user profiles. Generates requested sizes on demand just like Gravatar!
|
@@ -43,6 +43,9 @@ You can also use `get_simple_local_avatar()` (with the same arguments) to retrei
|
|
43 |
|
44 |
== Changelog ==
|
45 |
|
|
|
|
|
|
|
46 |
= 2.1 =
|
47 |
* *New:* All avatar uploads now go into the media library. Don't worry - users without the ability to upload files cannot otherwise see the contents of your media library. This allows local avatars to respect other functionality your site may have around uploaded images, such as external hosting.
|
48 |
* *New:* REST API support for getting and updating.
|
@@ -116,4 +119,4 @@ You can also use `get_simple_local_avatar()` (with the same arguments) to retrei
|
|
116 |
Upgraded to take advantage of *WordPress 3.5 and newer*. Does not support older versions! This has also *not* been tested with front end profile plug-ins - feedback welcome. Note that several language strings have been added or modified - revised translations would be welcome!
|
117 |
|
118 |
= 1.3.1 =
|
119 |
-
Like WordPress 3.2, now *REQUIRES* PHP 5.2 or newer.
|
3 |
Donate link: https://10up.com/plugins/simple-local-avatars-wordpress/
|
4 |
Tags: avatar, gravatar, user photos, users, profile
|
5 |
Requires at least: 4.6
|
6 |
+
Tested up to: 5.2
|
7 |
+
Stable tag: 2.1.1
|
8 |
Text Domain: simple-local-avatars
|
9 |
|
10 |
Adds an avatar upload field to user profiles. Generates requested sizes on demand just like Gravatar!
|
43 |
|
44 |
== Changelog ==
|
45 |
|
46 |
+
= 2.1.1 =
|
47 |
+
* Fixed: Do not delete avatars just because they don't exist on the local filesystem. This was occasionally dumping avatars when WordPress uploads were stored elsewhere, e.g. a cloud service.
|
48 |
+
|
49 |
= 2.1 =
|
50 |
* *New:* All avatar uploads now go into the media library. Don't worry - users without the ability to upload files cannot otherwise see the contents of your media library. This allows local avatars to respect other functionality your site may have around uploaded images, such as external hosting.
|
51 |
* *New:* REST API support for getting and updating.
|
119 |
Upgraded to take advantage of *WordPress 3.5 and newer*. Does not support older versions! This has also *not* been tested with front end profile plug-ins - feedback welcome. Note that several language strings have been added or modified - revised translations would be welcome!
|
120 |
|
121 |
= 1.3.1 =
|
122 |
+
Like WordPress 3.2, now *REQUIRES* PHP 5.2 or newer.
|
screenshot-1.png
ADDED
Binary file
|
simple-local-avatars.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: Simple Local Avatars
|
4 |
* Plugin URI: https://10up.com/plugins/simple-local-avatars-wordpress/
|
5 |
* Description: Adds an avatar upload field to user profiles. Generates requested sizes on demand, just like Gravatar! Simple and lightweight.
|
6 |
-
* Version: 2.1
|
7 |
* Author: Jake Goldman, 10up
|
8 |
* Author URI: https://10up.com
|
9 |
* License: GPLv2 or later
|
@@ -92,10 +92,6 @@ class Simple_Local_Avatars {
|
|
92 |
if ( ! empty( $local_avatars['media_id'] ) ) {
|
93 |
// has the media been deleted?
|
94 |
if ( ! $avatar_full_path = get_attached_file( $local_avatars['media_id'] ) ) {
|
95 |
-
// only allowed logged in users to delete bad data to mitigate performance issues
|
96 |
-
if ( is_user_logged_in() )
|
97 |
-
$this->avatar_delete( $user_id );
|
98 |
-
|
99 |
return $avatar;
|
100 |
}
|
101 |
}
|
3 |
* Plugin Name: Simple Local Avatars
|
4 |
* Plugin URI: https://10up.com/plugins/simple-local-avatars-wordpress/
|
5 |
* Description: Adds an avatar upload field to user profiles. Generates requested sizes on demand, just like Gravatar! Simple and lightweight.
|
6 |
+
* Version: 2.1.1
|
7 |
* Author: Jake Goldman, 10up
|
8 |
* Author URI: https://10up.com
|
9 |
* License: GPLv2 or later
|
92 |
if ( ! empty( $local_avatars['media_id'] ) ) {
|
93 |
// has the media been deleted?
|
94 |
if ( ! $avatar_full_path = get_attached_file( $local_avatars['media_id'] ) ) {
|
|
|
|
|
|
|
|
|
95 |
return $avatar;
|
96 |
}
|
97 |
}
|