Fix changeset construction special case for empty commits in pre-commit hooks
Summary: Fixes T13155. Ref T13151. A recent change (D19455) changed the return format here, but I missed this special case for empty commits.
Test Plan:
  - T13155 has a good set of reproduction instructions.
  - Pushed an empty commit.
    - Before: bunch of warning log spew.
    - After: clean logs.
Reviewers: amckinley, avivey
Reviewed By: avivey
Maniphest Tasks: T13155, T13151
Differential Revision: https://secure.phabricator.com/D19500
			
			
This commit is contained in:
		| @@ -1212,7 +1212,7 @@ final class DiffusionCommitHookEngine extends Phobject { | |||||||
|  |  | ||||||
|     if (!strlen($raw_diff)) { |     if (!strlen($raw_diff)) { | ||||||
|       // If the commit is actually empty, just return no changesets. |       // If the commit is actually empty, just return no changesets. | ||||||
|       return array(); |       return array(array(), 0); | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     $parser = new ArcanistDiffParser(); |     $parser = new ArcanistDiffParser(); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 epriestley
					epriestley