OutputStreamQuery: Take files into account when adding patch sets

The original fix for issue 3762 did not consider whether files should be
included in the patch set or not. Fix this by using the overload of
addPatchSets() which takes the includeFiles argument.

Bug: Issue 3877
Change-Id: Ie594b93d65bae6cdc353ba22ac1f2d558689a76a
diff --git a/gerrit-server/src/main/java/com/google/gerrit/server/query/change/OutputStreamQuery.java b/gerrit-server/src/main/java/com/google/gerrit/server/query/change/OutputStreamQuery.java
index ebce61e..1825b91 100644
--- a/gerrit-server/src/main/java/com/google/gerrit/server/query/change/OutputStreamQuery.java
+++ b/gerrit-server/src/main/java/com/google/gerrit/server/query/change/OutputStreamQuery.java
@@ -236,7 +236,9 @@
           if (includeComments) {
             eventFactory.addComments(c, d.messages());
             if (includePatchSets) {
-              eventFactory.addPatchSets(c, d.patches(), labelTypes);
+              eventFactory.addPatchSets(c, d.patches(),
+                  includeApprovals ? d.approvals().asMap() : null,
+                  includeFiles, d.change(), labelTypes);
               for (PatchSetAttribute attribute : c.patchSets) {
                 eventFactory.addPatchSetComments(attribute,  d.publishedComments());
               }