Go to file
Scott Taylor a7c1728f2e Reinstate the changes from [28579] with some adjustments:
* Check `! empty( $postarr['file'] )` before calling `update_attached_file()`
* Add a unit test: `test_update_attachment_fields()`
* Run the same logic for empty `guid` for attachments that always ran in `wp_insert_post()`, as per #18310. This fixes a unit test that would have broken when this ticket was marked closed.
* Updated the unit test in `Tests_Media::test_wp_prepare_attachment_for_js()` to account for `url` no longer being empty

Props kovshenin, wonderboymusic.
See #21963.


git-svn-id: https://develop.svn.wordpress.org/trunk@28788 602fd350-edb4-49c9-b593-d223f7449a82
2014-06-20 18:26:17 +00:00
src Reinstate the changes from [28579] with some adjustments: 2014-06-20 18:26:17 +00:00
tests Reinstate the changes from [28579] with some adjustments: 2014-06-20 18:26:17 +00:00
tools/i18n
.editorconfig
.gitignore Remove twenty* ignore-exclusion lines. Already tracked. 2014-02-26 20:59:25 +00:00
.jshintrc
.travis.yml
Gruntfile.js
package.json
phpunit.xml.dist
wp-cli.yml
wp-config-sample.php
wp-tests-config-sample.php