1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2024-11-26 00:32:41 +01:00

Mark moved binary file as image

Test Plan: Moved image, verified that the source file is marked as image: https://secure.phabricator.com/differential/diff/6924/

Reviewers: epriestley, btrahan

Reviewed By: btrahan

CC: aran, Korvin

Differential Revision: https://secure.phabricator.com/D3520
This commit is contained in:
vrana 2012-09-18 15:07:01 -07:00
parent 1d744e932f
commit 7119f0c4cc

View file

@ -1028,7 +1028,8 @@ EOTEXT
$change->setMetadata('new:file:size', $new_dict['size']);
$change->setMetadata('new:file:mime-type', $new_dict['mime']);
if (preg_match('@^image/@', $new_dict['mime'])) {
$mime_type = coalesce($new_dict['mime'], $old_dict['mime']);
if (preg_match('@^image/@', $mime_type)) {
$change->setFileType(ArcanistDiffChangeType::FILE_IMAGE);
}
}