DiscourseEvent.trigger for single sign on


I’d like like to implement something like @thomaspurchas GitHub - WarwickFilmSoc/discourse-group-sync: Automatic group sync from Filmsoc to Discourse plugin but without the sync part. Really, I think it would be awesome if there was a hook that ran after single sign on so a plugin could process custom fields passed back during the sign on process.

If someone already knows of a way to do this let me know. Otherwise, I’m proposing adding a DiscourseEvent.trigger(:sso_user_login) somewhere in the lookup_or_create_user method: discourse/discourse_single_sign_on.rb at 19ca08857fba1b74669af0568e1abe9932b84866 · discourse/discourse · GitHub