Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
// Before 8.7.0 only this was possible.
file_unmanaged_copy($source, $destination);
// After 8.7.0 this is the new way. The prior code still works but is deprecated.
\Drupal::service('file_system')->copy($source, $destination);
We should switch to the new code at some point.
Comment | File | Size | Author |
---|---|---|---|
#5 | file_unmanaged_copy_deprecated-3054210-5.patch | 2.64 KB | R.shaikh |
Comments
Comment #2
oknateComment #3
oknateComment #4
R.shaikh CreditAttribution: R.shaikh at Asentech LLC commentedComment #5
R.shaikh CreditAttribution: R.shaikh at Asentech LLC commented@Nate Andersen (oknate).. I have made changes as you suggested.
Kindly review.
Comment #6
R.shaikh CreditAttribution: R.shaikh at Asentech LLC commentedComment #7
oknateLooks goods.
Comment #10
oknateCommitted, thanks. Since this only affects the tests, I think it's fine to commit. Most likely no one will be running the tests for the module on less than Drupal 8.7.