Thank you both so much, I believe it now works as intended as files are stored in the moodledata folder.
My issue is now fetching those stored files, I'm not sure which Moodle function could help me with that ?
My issue is now fetching those stored files, I'm not sure which Moodle function could help me with that ?