I have a custom-made Joomla 3 component used to create users in the frontend and adding some fields to another table. Now, I must change a bit this procedure: I must send an email to the new user with his username and password when he's registered.
In teory, this is really trivial. In my model, I should update the save() function, and after saving I send the email. And that's correct. But the problem is: how can I know that I'm creating a new user, and not updating and old user? I've been looking at Joomla3's documentation, but I don't know how to do this...
Can you help me, please?