Have recently starting using UserFrosting to as part of a project and I'm having some problems using Facades within UserFrosting and would appreciate some help if possible.
I am attempting to use the File
facade from within a UserFrosting controller to create a folder on the local filesystem using the following code
use Illuminate\Support\Facades\File; ...... $directoryCreated = File::makeDirectory($directoryPath);
However at runtime i get the following error
PHP Fatal error: Call to a member function makeDirectory() on null in /var/www/test-app/userfrosting/vendor/illuminate/support/Facades/Facade.php on line 210
It seems that the UserFrosting app does not recognise the File facade (or any other facacde - i also tried Storage) and it has not been registered with the app.
Is it possible to use the facade classes with UserFrosting?
If so do I have to register them somewhere within the UserFrosting app config?
Any direction pointers would be greatly appreciated.
Thanks in advance!
from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/2dkOLie
via IFTTT
Aucun commentaire:
Enregistrer un commentaire