Thanks mate. Hmm it appears I was running a redis-server that I hadn't told to be persistent. Damn. Thanks for the help anyway 🙂
[nodebb-plugin-session-sharing] How to lookup user only by username?
I ask this because the user IDs of my site's users are different from their corresponding NodeBB uids.
If I don't provide uid, the plugin doesn't work.
If I do provide the uid, the plugin is unable to find the user, because as i mentioned above, the user IDs on the main site don't match NodeBB's. Any idea on what to do?
In case it's relevant, I used
nodebb-plugin-importto import data from a previous forum.
You should store a map of your site's format to the respective NodeBB uid for each user in a database.
nodebb-plugin-session-sharingstores remoteId->nbbId mapping and allows getting the userdata for it take alook here https://github.com/julianlam/nodebb-plugin-session-sharing/blob/master/library.js#L130-L141
@pitaj Could you give me a couple pointers as to how I would go about this? I'm a bit confused ^^"
@teresa-hale-dhq I suggest you use the API baris gave you. The session-sharing plugin provides this for you
Update: I figured out how to merge the accounts -- I just had to supply an email and the plugin did the rest.
But now I have another problem: How do I access the user's remote ID from the template? So that when someone clicks on the username/icon, they're redirected to my application's profile page as opposed to NodeBB's?