I'm working on a meteor project and one of its functionality is for users to upload their pictures in their profile. I wanted to create a new folder in the public directory (i.e public/img/user_id/files_to_upload_here.jpg), every time a new user is created.
Accounts.onCreateUser(function(options, user) {
//code to create a folder
});
How can I achieve that?
Thanks!
I think you can directly use the function from the node API:
Doc
You also have the async method which do the same.