Trust level 3 user title disappearing

Anyone faced a issue when it comes to trust level 3 users? They can set their own title, but when they set it, it disappears at some point by its own ?

We do use SSO through API, ill check if its related to that.

1 Like

That sounds like the most likely explanation. Check to see whether your SSO payload includes a title attribute.

1 Like

I just checked but it doesnt include title. does this mean that it gets overwritten?

Am i able to somehow tell dikscourse to not override it and preserve the title user set in discourse? if the case is that not setting means overriding to no title?

SSO will only update the title if you provide it in the payload. Note that if you provide a blank string, then it will be set to a blank string.

https://github.com/discourse/discourse/blob/88ecb650a98921e5e3cd345e29f84d9dd204b777/app/models/discourse_single_sign_on.rb#L98

If you’re not passing any title, then the issue must be something else. Do you have some steps to reproduce the problem?

2 Likes

We are not passing the title at all during SSO.

I will try to reproduce it, i got this information from a user in our service. Another strange thing is that if you watch the users settings you see that it doesn’t have a title kuva

but i go to admin view, then i see that the user has a title again

This is an exmaple of a user whos title is acctually not overwritten for a very long time.

is there a difference between these 2 titles? one in the settings page and another in the admin user settings page? O.o

1 Like

@david hi i can reproduce this now.

I made a new account and granted myself level 3 trust level

Then i put set my title and refresh page and it is gone.

Didn’t need to log out and log in or anything just refresh page after setting.

MORE INFO:

it seems that if i set the title as admin for the level 3 user, then the user can refresh and use the title as much as he /she wants. But if the user with level 3 trust level sets it as “no title” and sets the what ever title back on, then refresh again removes all settings again.

I changed the category to bug, since it feels like this is something that should not be happening.

1 Like

Did the user click save before refreshing? I just tested this on try.discourse.org as a TL3 users, and could not reproduce the issue.

Yes I pushed save as level 3 user. When I tried with my test account. You can try on our instance hosted by discourse keskustelut.inderes.fi and the test user is called discourse_test as the screenshot above. This user is with level 3 trust level.

Test process

  1. make sure TL 3 does not have title.
  2. log in as tl3
  3. go to profile settings and set title from drop-down and save
  4. refresh page
  5. title should dissapear.
1 Like

Yeah, those are the exact steps I followed on try. Let me log into your site and give it a go.

1 Like

OK, so this is very strange. It seems to be locale related. When the site is in Finnish, the default, saving a title does not appear to work. When I enabled allow user locale and changed the discourse_test user’s locale to English (United States), saving worked as expected. @gerhard, any thoughts?

3 Likes

That’s a known problem. I’ll have a look at the beginning of next week. I’m closing this topic as duplicate.

6 Likes