humanmade / humanmade/S3-Uploads
Warning: copy(): The second argument to copy() function cannot be a directory in /var/www/html/wp-content/plugins/s3-uploads/inc/class-s3-uploads.php on line 226
- Dominant language
- PHP
- Stars
- 2.2k
- Forks
- 404
- PR merge metrics
- No merged PRs in 30d
Description
When using the plugin and using the upload manually, `$upload = wp_handle_sideload($file, array('test_form' => false));` I am getting an error. The second argument passed in to `copy` is the temporary file name, so I don't know why it is complaining. If I add a file extension, then it works.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start at inc/class-s3-uploads.php line 226 and trace the copy() call reached through wp_handle_sideload() when the uploaded file has no extension. Reproduce the warning with a manually uploaded file, then verify that sideloading extensionless files completes without the directory warning while existing uploads continue to work.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, php
- Domain
- backend, cloud
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100