Skip to content

Commit

Permalink
Update deprecation notice language
Browse files Browse the repository at this point in the history
  • Loading branch information
alcaeus committed Sep 24, 2024
1 parent 09c78e3 commit 6105187
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/Collection.php
Original file line number Diff line number Diff line change
Expand Up @@ -956,7 +956,7 @@ public function listSearchIndexes(array $options = []): Iterator
*/
public function mapReduce(JavascriptInterface $map, JavascriptInterface $reduce, string|array|object $out, array $options = [])
{
@trigger_error(sprintf('The %s method is deprecated and will be removed in a future release.', __METHOD__), E_USER_DEPRECATED);
@trigger_error(sprintf('The %s method is deprecated and will be removed in a version 2.0.', __METHOD__), E_USER_DEPRECATED);

$hasOutputCollection = ! is_mapreduce_output_inline($out);

Expand Down
4 changes: 2 additions & 2 deletions src/Model/IndexInfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ public function getName()
*/
public function getNamespace()
{
@trigger_error('MongoDB 4.4 drops support for the namespace in indexes, the method "IndexInfo::getNamespace()" will be removed in a future release', E_USER_DEPRECATED);
@trigger_error('MongoDB 4.4 drops support for the namespace in indexes, the method "IndexInfo::getNamespace()" will be removed in version 2.0', E_USER_DEPRECATED);

return (string) $this->info['ns'];
}
Expand Down Expand Up @@ -132,7 +132,7 @@ public function is2dSphere()
*/
public function isGeoHaystack()
{
@trigger_error('MongoDB 5.0 removes support for "geoHaystack" indexes, the method "IndexInfo::isGeoHaystack()" will be removed in a future release', E_USER_DEPRECATED);
@trigger_error('MongoDB 5.0 removes support for "geoHaystack" indexes, the method "IndexInfo::isGeoHaystack()" will be removed in version 2.0', E_USER_DEPRECATED);

return array_search('geoHaystack', $this->getKey(), true) !== false;
}
Expand Down
2 changes: 1 addition & 1 deletion src/Operation/CreateCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ public function __construct(private string $databaseName, private string $collec
}

if (isset($this->options['autoIndexId'])) {
trigger_error('The "autoIndexId" option is deprecated and will be removed in a future release', E_USER_DEPRECATED);
trigger_error('The "autoIndexId" option is deprecated and will be removed in version 2.0', E_USER_DEPRECATED);
}

if (isset($this->options['pipeline']) && ! is_pipeline($this->options['pipeline'], true /* allowEmpty */)) {
Expand Down

0 comments on commit 6105187

Please sign in to comment.