-
Notifications
You must be signed in to change notification settings - Fork 264
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PHPLIB-1609 Don't mandate the use of "distanceField" in $geoNear
#1569
Conversation
The $geoNear distanceField argument is now optional for queries on non-timeseries collections.
@@ -265,8 +265,8 @@ public static function fill( | |||
* Default: false. | |||
*/ | |||
public static function geoNear( | |||
string $distanceField, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The parameter was put first because required parameters must be before the optional ones. Changing the order of the parameters would be a breaking change one the library is released.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I worry that the server being able to make such changes at will (where we might require a BC break to maintain consistency) is going to inevitably become a problem down the line.
Had you not caught this before a release, how could PHPLIB-1609 have been implemented?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change looks fine but I'm concerned about how we might get screwed over by a similar change down the line.
@@ -265,8 +265,8 @@ public static function fill( | |||
* Default: false. | |||
*/ | |||
public static function geoNear( | |||
string $distanceField, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I worry that the server being able to make such changes at will (where we might require a BC break to maintain consistency) is going to inevitably become a problem down the line.
Had you not caught this before a release, how could PHPLIB-1609 have been implemented?
Fix PHPLIB-1609 see DRIVERS-3071
The
$geoNear
distanceField argument is now optional for queries on non-timeseries collections.