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

media copied to incorrect sub-directory on clone #56

Open
3wf opened this issue Jul 17, 2018 · 0 comments
Open

media copied to incorrect sub-directory on clone #56

3wf opened this issue Jul 17, 2018 · 0 comments

Comments

@3wf
Copy link

3wf commented Jul 17, 2018

Thanks for the great plugin!

Currently I'm having a problem where image attachments often don't come across with a duplication.

I think it's because the file is being copied over from the source but in mpd_copy_file_to_destination() it's using WP functions to create the destination meta data around the attachment which is different if the copy is made when the attachment month has updated.

For example, copying a custom post has the following attachment
./sites/7/2018/04/winemaker_quote_img_vines02_fs_2x-150x150.jpg

And it copies the file to
./sites/6/2018/04/winemaker_quote_img_vines02_fs_2x-150x150.jpg

But the WP media library is looking for
./sites/6/2018/07/winemaker_quote_img_vines02_fs_2x-150x150.jpg

Because WP is now putting attachments into 2018/07

@3wf 3wf changed the title different sub-directory for media attachment on clone media copied to incorrect sub-directory on clone Jul 17, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant