I get the following error when using $wp_filesystem->copy(); to copy a file from one destination to another.

Undefined variable: temphangle in <b>../htdocs/wp-admin/includes/class-wp-filesystem-ftpext.php</b> on line <b>159</b>

Any idea what temphangle is?

1 Answer 1


It appears to be a typo corrected by SergeyBiryukov in the Github Repo for 5.6 :


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.