Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Warning: mkdir(): No such file or directory #6

Closed
stuartcusackie opened this issue Aug 12, 2020 · 4 comments · Fixed by #7
Closed

Warning: mkdir(): No such file or directory #6

stuartcusackie opened this issue Aug 12, 2020 · 4 comments · Fixed by #7

Comments

@stuartcusackie
Copy link

stuartcusackie commented Aug 12, 2020

Seems to problem with v1.5 with a fresh Roots set up. On saving my first ACF group I get this error:

Warning: mkdir(): No such file or directory in /srv/www/mysite.test/current/web/app/themes/mytheme/vendor/mwdelaney/sage-advanced-custom-fields/advanced-custom-fields.php on line 34

I have downgraded to v1.4 and I see no issues there.

@jopfre
Copy link

jopfre commented Nov 18, 2020

Workaround is to create the acf-json directory manually in /resources/assets

@YarGnawh
Copy link

YarGnawh commented Jan 3, 2021

Maybe change

to mkdir($path, 0777, true);

@catgofire
Copy link
Contributor

In the latest Sage they flattened the resources/ directory... there is no longer a resources/assets/ dir. Eventually this should be changed:

// This is Sage 10
$path = get_stylesheet_directory() . '/resources/assets/acf-json';

to

// This is Sage 10
$path = get_stylesheet_directory() . '/resources/acf-json';

@MWDelaney
Copy link
Owner

This is a great. We should probably add a conditional to check the existence of the first directory and fall back to the second. I'll take a stab at this unless someone here wants to make a PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants