I know the avatar of the person who deleted a post used to show up at the bottom but now I no longer see it. Was this an intentional design choice?
I see what you mean. It is easier to see who deleted the post from the post as opposed to going to the logs.
I donât think it was an intentional change. The code is still there. I think something broke when the post widgets were updated to Glimmer components.
When I change this to
{{#if @post.deleted_at}}
and also edit line 14
{{formatDate @post.deleted_at format="tiny"}}
I am able to restore most of it.
But I wasnât able to make the avatar work. Based on
I thought it would be
<UserAvatar @size="tiny" @user={{@post.deleted_by}} />
but that didnât work.
Jumping in here, thanks for the detailed breakdown, Moin. I tried a similar tweak and ran into the same issue with the avatar not displaying. It looks like @post.deleted_by
isnât getting passed correctly to the component, even though the model has the deleted_by
property. Maybe itâs not being included in the post serializer or not tracked correctly through the Glimmer component layer?
Might be worth checking if deleted_by
is exposed in the API response for the post. If not, that could explain why UserAvatar
isnât getting any user data. Just a thought. Curious if anyoneâs found a full fix.
What did you try?
Great idea! Would you do that and share the result?
Thank you for the detailed report.
It is indeed a small bug introduced with the Glimmer components.
Iâll fix it as soon as possible.
The issue will be fixed by the PR above.