Skip to content
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

rid of deprecated mongodb methods #35

Closed
wants to merge 1 commit into from

Conversation

debianw
Copy link
Contributor

@debianw debianw commented Feb 20, 2019

New mongodb client (3.1.10) which is in package-lock.json is throwing warnings like:

  • DeprecationWarning: collection.ensureIndex is deprecated. Use createIndexes instead
  • DeprecationWarning: collection.ensureIndex is deprecated. Use createIndexes instead.
  • DeprecationWarning: collection.insert is deprecated. Use insertOne, insertMany or bulkWrite instead

This PR will fix those by using the new methods.

@codecov-io
Copy link

codecov-io commented Feb 20, 2019

Codecov Report

Merging #35 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master      #35   +/-   ##
=======================================
  Coverage   97.89%   97.89%           
=======================================
  Files           2        2           
  Lines         237      237           
  Branches       49       50    +1     
=======================================
  Hits          232      232           
  Misses          5        5
Impacted Files Coverage Δ
mongo.js 91.17% <100%> (ø) ⬆️
index.js 99.01% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update fe5a17b...0249091. Read the comment docs.

@mateodelnorte
Copy link
Owner

Hi @debianw. Thanks for this PR, and apologies for missing it. Any chance you can rebase against master and push? We'll get this merged in.

patrickleet pushed a commit that referenced this pull request May 26, 2020
patrickleet added a commit that referenced this pull request May 26, 2020
BREAKING CHANGE: Now defaults to new mongo db client options `useNewUrlParser` and `useUnifiedTopology`. Travis changed to test last two Node versions, 12 and 14.

* feat: mongodb replica set support

* chore: add 10 to tests

* fix: lock to sourced 2.0.5

* fix: sourced bug - upgrade to fixed 2.0.7

* fix: [email protected]

* chore: update travis file

* chore: rm debug log statements

* chore: rm debug log statements

* fix: make options configurable

* fix: cherry pick changes from @debianw - PR #35

Co-authored-by: Waly <[email protected]>
@patrickleet
Copy link
Collaborator

cherry picked and included in #43

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants