Deletes the attachment/uploaded file.
Source
public function cleanup() {
if ( $this->id ) {
wp_delete_attachment( $this->id );
} elseif ( file_exists( $this->package ) ) {
return @unlink( $this->package );
}
return true;
}
Changelog
Version | Description |
---|---|
3.2.2 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.