Skip to content

Commit 790ba9c

Browse files
alcaeusjmikola
andauthored
Apply suggestions from code review
Co-authored-by: Jeremy Mikola <[email protected]>
1 parent 0e504d9 commit 790ba9c

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

tests/AggregationBlogPost/article.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -122,11 +122,11 @@ Without going into more details on this, even if we were to comment on parts of
122122
the aggregation pipeline to explain what it does, there will still be a high
123123
cognitive load when going through the aggregation pipeline. One reason for this
124124
is that the only way to express the aggregation framework domain-specific
125-
language (DSL) is through untyped arrays, and any PHP editor can't provide much
125+
language (DSL) is through untyped arrays, for which a PHP editor provides little
126126
help beyond syntax highlighting. Pair that with a few levels of nesting, and
127127
you've got yourself the kind of code that you can write, but not read. We could
128128
start off by refactoring the code, but instead let's try to move away from array
129-
structures and use a better solution.
129+
structures and towards a better solution.
130130

131131
## Introducing the Aggregation Pipeline Builder
132132

@@ -743,9 +743,9 @@ function _match(...) {}
743743
function _switch(...) {}
744744
```
745745

746-
We also decided against this option, partly because the underscore marks (or at
747-
least used to mark) private functions or methods, but also because the
748-
underscore would break alphabetical sorting in code completion.
746+
We also decided against this option, partly because underscores have
747+
historically been used to mark private methods and properties, but also
748+
because the underscore would break alphabetical sorting in code completion.
749749

750750
A less-than-serious approach was to use emojis, which I learned was valid in
751751
PHP:
@@ -789,7 +789,7 @@ $group(
789789
);
790790
```
791791

792-
Again, PHP's use of `$` to mark variables plays nice with aggregation pipeline
792+
Again, PHP's use of `$` to mark variables plays nice with the aggregation framework
793793
using it for stages and operators. We have considered adding a method to each
794794
factory class that would return an array of closures to make this easier:
795795

@@ -800,5 +800,5 @@ factory class that would return an array of closures to make this easier:
800800
extract(Accumulator::accumulators());
801801
```
802802

803-
We have not implemented this for now, but if you prefer this syntax to static
803+
We have decided not implemented this for now, but if you prefer this syntax to static
804804
methods, or if you have alternative suggestions, please let us know about them!

0 commit comments

Comments
 (0)