solved Followers sometimes get doubled listing in 'my followers' list

Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
This has only started happening in the past couple of months or so. It has not effected OLDER follows in the lists, only 'follows' that were more recently created.
It does not happen all the time, or to all members. It's not something only happening to or only visible by Admins... other members are experiencing it here and there.
I see it occurring in my followers page of my profile "Forums" which i use to house the site forums... however it's NOT occurring in my master admin Strumelia profile.
Also, it only occurs in the /follow page of any of these profiles, it does NOT occur in their /follow/following pages.
But it's causing a problem because a regular member has reported that when they saw it, they clicked on ONE of the twin items to delete the duplicate, and the action deletes BOTH instances of the follower.
It's understandable to try to delete one of the two twins, but doing that deletes them BOTH.

- At first I thought it only happened to me maybe because I have more than one profile. But no, regular members who are limited to only one profile are experiencing it lately. It occurs seemingly randomly. When I look at the html source code for the page, I can see the code listing those certain followers and their avatars twice.
Let me give a few screenshots to help clarify....

Here it is happening on two random regular member profiles... note that it's only happening with random more recent follows, not the older follows from long ago.:

bob.png
bob.png  •  562KB

richard.png
richard.png  •  659KB




--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015

updated by @strumelia: 10/04/18 04:07:46PM
Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
And here is is happening quite a bit for my own "Forums" profile:
forums profile.jpg
forums profile.jpg  •  224KB




--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015
Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
But for some reason it is not happening in my main (master admin) profile:
strumelia.jpg
strumelia.jpg  •  199KB




--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015
michael
@michael
6 years ago
7,715 posts
In your jrFollower item_index.tpl template (yours is custom) I've added
group_by="_profile_id"
so double items are grouped together.

It now reads:
 {jrCore_list module="jrFollower" search1="follow_profile_id = `$_profile_id`" order_by="_created desc" pagebreak=40 page=$_post.p template=$ftpl pager=true group_by="_profile_id" }

That should fix it.
Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
Ah, thank you very much Michael! :)
I've applied the same fix to my other jr site.


--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015
michael
@michael
6 years ago
7,715 posts
nice one! :thumbs-up:
Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
I'm revisiting this thread because I've noticed that although the above fix works nicely to eliminate the 'twin' followers from appearing on the member's https://fotmd.com/strumelia/follow page, the doubled followers still appear on the member's main profile Sidebar widget- see this screenshot.
I probably just didn't notice this in the sidebar after the above fix successfully fixed the issue on the main Follow page for the larger follower avatars.
I'm guessing I'm going to need to apply the same 'type' of code fix in my custom skin's the profile sidebar, or index template? OR maybe somewhere else.. somehow pointing to the profile Sidebar? Not sure.
doublefollowers.jpg
doublefollowers.jpg  •  585KB




--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015
michael
@michael
6 years ago
7,715 posts
group_by="_profile_id" 
is the key. :)

--edit--
Add that to the jrCore_list call that is generating that list of followers.
updated by @michael: 04/29/18 09:43:16PM
Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
Ok, so after getting sidetracked for a few weeks, I came back to this and (finally) figured out to apply your code snippet to my custom skin template: profile_sidebar.tpl ...in the 'followers' core list call section there. It worked- thank you! All solved. :D


--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015
Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
I'm afraid I have to revisit this issue, because I've had some regular members report that they are STILL seeing doubled follower avatars in both locations, despite hard refreshing browsers and integ checks etc.
It appears that in doing the above fixes, it has only fixed the issue for myself (Admin) and for my regular test member -that test profile was created long ago by a former Admin, so apparently retains some 'stuck' attributes that are messing up my objective view. Using that particular test member caused me to believe this issue was solved... but it's not solved.

After receiving new reports of the double avatar from a real regular member, I just now created a new 'test' regular member from scratch (one that was not created by me as master admin as a sub-profile), and when logged in as that new test member I too now see the double avatars in both places... see SCREENSHOT attached here.
One can also easily see the double avatars identical to the screenshot when NOT logged in at all... see here on a sample of a random member profile page showing twin follower avatars in the TWO places: both her "My Followers" TAB and also in her profile sidebar 'latest followers' grid:
https://fotmd.com/ariane/follow

So it seems the fixes above that I've applied have only fixed it for site viewers that are Admin-associated.
twins.jpg
twins.jpg  •  334KB




--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015

updated by @strumelia: 06/13/18 09:05:43AM
michael
@michael
6 years ago
7,715 posts
You have an IF/ELSE in your jrFollower item_index.tpl
https://fotmd.com/follow/template_modify/id=70

The
group_by="_profile_id" 
is only being applied to the profile owners version of the list. Add it to the other list too and you'll get the same results for each.
if_else.jpg
if_else.jpg  •  64KB

Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
Ok thank you for your help... I did this as you suggest Michael. I then did integrity check, also cleared cache, also did a browser hard refresh, closed and reopened browser. It does not seem to help in any way.

Here's what's happening.. and I'm seeing it on various member profiles, but this is a good example one to see it happening on:
https://fotmd.com/ariane/follow She's the regular member who wrote to me many weeks ago that she was seeing this on her profile and on other member profiles.

When I am logged in as Master admin (Strumelia), or as my OTHER 'test' Master admin (Martha Campbell)... I do NOT see double Follower avatars anywhere- on my own profile or other member profiles.

I DO see the double avatars (on other people's profile pages and on my own) in all these other instances:
- when logged OUT
- when logged in as my test Profile Admin
- when logged in as my new 'test' regular member (that I created from scratch yesterday, unrelated to any admin accounts)
- plus, regular member Ariane is reporting to me that she still sees the doubles on her own and other member profiles, despite the fixes above that I've applied so far.

Should I maybe open a support ticket on this and give you logins for the various test accounts I have in different quotas?
Oh, here again is the screenshot on what is being seen for example on real member Ariane's Follow page:
twins.jpg
twins.jpg  •  334KB




--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015

updated by @strumelia: 06/14/18 09:19:19AM
michael
@michael
6 years ago
7,715 posts
Looks like a bug related to search conditions and the privacy check.

Looking into it.
michael
@michael
6 years ago
7,715 posts
Brians found a fix for this and it will be in an upcoming release of the core.
Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
Thank you for this good news update! I continue to get members asking me about it now and then.
I can't help but wonder if this is happening only to me.
Thx!


--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015
michael
@michael
6 years ago
7,715 posts
I think its related to the FriendsToFollowers module but don't know how to reproduce it. Without that, going searching for how to make it happen is lower priority.
brian
@brian
6 years ago
10,148 posts
There's really 2 issues here:

- There should not be duplicates in the followers datastore
- When using a "group_by" on the _profile_id key it's not working in a specific instance

I've got #2 fixed for the next core release which will "mask" issue 1 for you on your site, but we're checking on why duplicates were created in the first place.


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
The only clues I can give you are:
1) when I'm logged IN as either master admin or a profile admin, I don't see duplicates on anyone's profile.
2) when I'm logged OUT, or when I;m logged in as a regular member, I see duplicates on my own and all member profiles, including on admin profiles.
3) the duplicates dont happen for OLDER follows that happened a while back..., they only appear for 'some' follows that have occurred say around the past 6 months or so.
Also, they don't appear for all Follows, just some (can't figure out a pattern there, and doesn't seem related to 'pending followers' at all).


--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015

updated by @strumelia: 07/01/18 06:57:48AM
Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
brian:
- There should not be duplicates in the followers datastore
I've got #2 fixed for the next core release which will "mask" issue 1 for you on your site, but we're checking on why duplicates were created in the first place.

Brian, perhaps this is another clue: if the profile owner deletes ONE of the twins from their follow list, the other one is removed as well and that person is no longer a follower.


--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015
Strumelia
Strumelia
@strumelia
6 years ago
3,603 posts
brian:
There's really 2 issues here:
- There should not be duplicates in the followers datastore
- When using a "group_by" on the _profile_id key it's not working in a specific instance

I've got #2 fixed for the next core release which will "mask" issue 1 for you on your site, but we're checking on why duplicates were created in the first place.

Brian, I've applied the new Core update, and your 'masking fix' is indeed working. So thanks so much for that, my members will be relieved! (they kept accidentally deleting their followers, because when they clicked to remove ONE of the twins --as anyone might predictably do-- BOTH were deleted from their follower list)
I know you will still be investigating the 2 factors you've listed above. But just wanted to let you know your Core masking fix worked and I'm real happy about that. :)

You can mark this thread as any status you see fit now, since I'm not sure how it would be best categorized now. THANKS!!


--
...just another satisfied Jamroom customer.
Migrated from Ning to Jamroom June 2015
brian
@brian
6 years ago
10,148 posts
Glad to hear that. The duplicate issue is something we're looking into - it may require so low level re-plumbing of how the module works, so it's not something we'll have out right away.


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net