Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jdesboeufs/connect-mongo
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: f4c8fa5d04777c0017f5123a10b71577de248d45
Choose a base ref
...
head repository: jdesboeufs/connect-mongo
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 63ca966852cdc87148178afc3063433e07a41af3
Choose a head ref

Commits on Aug 20, 2016

  1. Update to #228

    Still receiving this error after 1.3.2.
    
    TypeError: Cannot read property 'upserted' of undefined
         at /root/app/node_modules/connect-mongo/src/index.js:251:36
         at tryCatcher (/root/app/node_modules/connect-mongo/node_modules/bluebird/js/release/util.js:16:23)
         at Promise._settlePromiseFromHandler (/root/app/node_modules/connect-mongo/node_modules/bluebird/js/release/promise.js:504:31)
         at Promise._settlePromise (/root/app/node_modules/connect-mongo/node_modules/bluebird/js/release/promise.js:561:18)
         at Promise._settlePromise0 (/root/app/node_modules/connect-mongo/node_modules/bluebird/js/release/promise.js:606:10)
         at Promise._settlePromises (/root/app/node_modules/connect-mongo/node_modules/bluebird/js/release/promise.js:685:18)
         at Promise._fulfill (/root/app/node_modules/connect-mongo/node_modules/bluebird/js/release/promise.js:630:18)
         at /root/app/node_modules/connect-mongo/node_modules/bluebird/js/release/nodeback.js:45:21
         at /root/app/node_modules/mongojs/lib/collection.js:105:7
         at handleCallback (/root/app/node_modules/mongodb/lib/utils.js:96:12)
         at /root/app/node_modules/mongodb/lib/collection.js:1034:5
         at /root/app/node_modules/mongodb/node_modules/mongodb-core/lib/connection/pool.js:428:18
         at nextTickCallbackWith0Args (node.js:420:9)
         at process._tickDomainCallback (node.js:390:13)
    buzzcloudau authored Aug 20, 2016
    Copy the full SHA
    79727f6 View commit details

Commits on Nov 7, 2016

  1. avoiding calling touch in get

    `sessionStore.on('touch', ...)` gets called everytime currently, this change makes it work
    caub authored Nov 7, 2016
    Copy the full SHA
    2a958f6 View commit details

Commits on Nov 25, 2016

  1. Merge pull request #234 from buzzcloudau/patch-1

    Update to #228
    jdesboeufs authored Nov 25, 2016
    Copy the full SHA
    1021ce5 View commit details
  2. Merge pull request #246 from caub/patch-1

    avoiding calling touch in get
    jdesboeufs authored Nov 25, 2016
    Copy the full SHA
    e513ccc View commit details

Commits on Dec 7, 2016

  1. Pass session too in the event

    I find it useful
    caub authored Dec 7, 2016
    Copy the full SHA
    af7d469 View commit details

Commits on Feb 23, 2017

  1. Copy the full SHA
    7124152 View commit details

Commits on Oct 5, 2017

  1. swap ensureIndex with createIndex fixes #268

    Ilario Engler authored Oct 5, 2017
    Copy the full SHA
    b7eab51 View commit details

Commits on Oct 8, 2017

  1. Merge pull request #248 from caub/patch-2

    Pass session too in the event
    jdesboeufs authored Oct 8, 2017
    Copy the full SHA
    55039ce View commit details
  2. Drop Node 0.12 support

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    5a29c35 View commit details
  3. Remove useless .babelrc

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    b5ef2bb View commit details
  4. Update repo refs

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    cbcaa59 View commit details
  5. Copy the full SHA
    6fcf22a View commit details
  6. Add yarn.lock

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    66674da View commit details
  7. Switch to xo

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    50ca3c9 View commit details
  8. Update mocha and nyc

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    c77f629 View commit details
  9. Merge branch 'patch-1' of git://github.com/ilarioengler/connect-mongo…

    … into ilarioengler-patch-1
    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    c979054 View commit details
  10. Copy the full SHA
    d673687 View commit details
  11. Drop MongoDB 2.x support

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    a769617 View commit details
  12. Use native promises

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    e130193 View commit details
  13. Copy the full SHA
    78799f2 View commit details
  14. Fix asCallback

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    a8b0fd4 View commit details
  15. Copy the full SHA
    ec8d667 View commit details
  16. Fix coverage

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    fe55d3d View commit details
  17. Fix version notation

    jdesboeufs committed Oct 8, 2017
    Copy the full SHA
    7276fae View commit details

Commits on Oct 9, 2017

  1. Update CHANGELOG

    jdesboeufs committed Oct 9, 2017
    Copy the full SHA
    51e7534 View commit details
  2. Update CHANGELOG

    jdesboeufs committed Oct 9, 2017
    Copy the full SHA
    fcbd1c3 View commit details
  3. Udate yarn.lock

    jdesboeufs committed Oct 9, 2017
    Copy the full SHA
    8541e55 View commit details
  4. v2.0.0

    jdesboeufs committed Oct 9, 2017
    Copy the full SHA
    fea1094 View commit details
  5. Copy the full SHA
    a4a9384 View commit details
  6. Update README.md

    jdesboeufs authored Oct 9, 2017
    Copy the full SHA
    88ae35a View commit details
  7. Merge pull request #271 from jdesboeufs/greenkeeper/initial

    Add Greenkeeper badge 🌴
    jdesboeufs authored Oct 9, 2017
    Copy the full SHA
    21899cf View commit details
  8. Add LICENSE

    jdesboeufs authored Oct 9, 2017
    Copy the full SHA
    509c873 View commit details

Commits on Dec 30, 2017

  1. do not use callback if it was not supplied

    Brian Andress committed Dec 30, 2017
    Copy the full SHA
    b7b48a2 View commit details
  2. add tests for promise without callback

    Brian Andress committed Dec 30, 2017
    Copy the full SHA
    1e09129 View commit details
  3. add gitignore entries for npm and nyc coverage

    Brian Andress committed Dec 30, 2017
    Copy the full SHA
    f10dad7 View commit details

Commits on Jan 4, 2018

  1. Merge pull request #276 from brainthinks/promise_cb_fix

    Promise cb fix
    jdesboeufs authored Jan 4, 2018
    Copy the full SHA
    4a2f07a View commit details
  2. Update CHANGELOG

    jdesboeufs committed Jan 4, 2018
    Copy the full SHA
    8d1a3ea View commit details
  3. v2.0.1

    jdesboeufs committed Jan 4, 2018
    Copy the full SHA
    9eb4d01 View commit details

Commits on Feb 24, 2018

  1. Copy the full SHA
    9684e5c View commit details

Commits on Feb 26, 2018

  1. Merge pull request #283 from klyburke/patch-1

    add showcase section to README
    jdesboeufs authored Feb 26, 2018
    Copy the full SHA
    d395dc3 View commit details

Commits on Mar 1, 2018

  1. Upgrade mocha and xo

    jdesboeufs committed Mar 1, 2018
    Copy the full SHA
    db34a49 View commit details
  2. Fix linting

    jdesboeufs committed Mar 1, 2018
    Copy the full SHA
    9f86f90 View commit details

Commits on Aug 11, 2018

  1. fix indentation

    SpolavoriBruno authored Aug 11, 2018
    Copy the full SHA
    edee723 View commit details

Commits on Sep 18, 2018

  1. Copy the full SHA
    36f42e5 View commit details
  2. Fix: test error at travis

    KSH-code committed Sep 18, 2018
    Copy the full SHA
    652823a View commit details

Commits on Sep 19, 2018

  1. Atomise

    Ryan Barwick committed Sep 19, 2018
    Copy the full SHA
    6d2bda4 View commit details
  2. Use set

    Ryan Barwick committed Sep 19, 2018
    Copy the full SHA
    909ebdd View commit details

Commits on Nov 20, 2018

  1. Merge pull request #303 from ryanbarwick/fix-error-fix

    Update deprecated methods
    jdesboeufs authored Nov 20, 2018
    Copy the full SHA
    52ff9d3 View commit details
  2. Update CHANGELOG

    jdesboeufs committed Nov 20, 2018
    Copy the full SHA
    b74f613 View commit details
  3. Rewind for np

    jdesboeufs committed Nov 20, 2018
    Copy the full SHA
    c90e121 View commit details
Showing with 6,919 additions and 1,128 deletions.
  1. +0 −9 .babelrc
  2. +39 −0 .eslintrc
  3. +0 −48 .eslintrc.yml
  4. +17 −0 .github/stale.yml
  5. +2 −0 .gitignore
  6. +9 −0 .npmignore
  7. +4 −0 .prettierrc.yml
  8. +16 −15 .travis.yml
  9. +7 −0 .vscode/settings.json
  10. +46 −1 CHANGELOG.md
  11. +21 −0 LICENSE
  12. +58 −44 README.md
  13. +1 −0 commitlint.config.js
  14. +0 −1 es5.js
  15. +1 −1 index.js
  16. +6 −0 jest.config.js
  17. +38 −26 package.json
  18. +154 −0 src/crypto.js
  19. +396 −283 src/index.js
  20. +66 −0 test/crypto.test.js
  21. +0 −8 test/es5-load.js
  22. +0 −66 test/events.js
  23. +140 −0 test/events.test.js
  24. +1 −0 test/jest.setup.js
  25. +0 −9 test/legacy-loader.js
  26. +0 −617 test/legacy-tests.js
  27. +570 −0 test/legacy-tests.test.js
  28. +5,327 −0 yarn.lock
9 changes: 0 additions & 9 deletions .babelrc

This file was deleted.

39 changes: 39 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"extends": [
"standard",
"prettier",
"prettier/standard",
"plugin:jest/recommended"
],
"parserOptions": {
"ecmaVersion": 9
},
"plugins": [
"prettier",
"jest"
],
"rules": {
"jest/no-disabled-tests": "error",
"prettier/prettier": "error",
"standard/no-callback-literal": "off",
"no-unused-vars": [
"error",
{
"args": "none",
"varsIgnorePattern": "^_",
"argsIgnorePattern": "^_"
}
],
"prefer-const": [
"error", {
"destructuring": "any",
"ignoreReadBeforeAssign": false
}
]
},
"env": {
"node": true,
"es6": true,
"jest/globals": true
}
}
48 changes: 0 additions & 48 deletions .eslintrc.yml

This file was deleted.

17 changes: 17 additions & 0 deletions .github/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Number of days of inactivity before an issue becomes stale
daysUntilStale: 60
# Number of days of inactivity before a stale issue is closed
daysUntilClose: 7
# Issues with these labels will never be considered stale
exemptLabels:
- pinned
- security
# Label to use when marking an issue as stale
staleLabel: wontfix
# Comment to post when marking an issue as stale. Set to `false` to disable
markComment: >
This issue has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs. Thank you
for your contributions.
# Comment to post when closing a stale issue. Set to `false` to disable
closeComment: false
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -3,3 +3,5 @@ node_modules/
coverage
src-es5
*.log
.nyc_output/
package-lock.json
9 changes: 9 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -3,8 +3,17 @@
History.md
Makefile
Readme.md
.DS_Store

examples/
support/
test/
coverage/
.vscode/
.github/
.eslintrc
.prettierrc.yml
.travis.yml
commitlint.config.js
.nyc_output/
jest.config.js
4 changes: 4 additions & 0 deletions .prettierrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
semi: false
singleQuote: true
trailingComma: es5
printWidth: 80
31 changes: 16 additions & 15 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -3,27 +3,28 @@ sudo: required
language: node_js

node_js:
- 0.12
- 4
- 6
- 8
- 10
- 12

env:
matrix:
- MONGODB=3.2
- MONGODB=3.4
- MONGODB=3.6
- MONGODB=4.0

services:
- docker

before_script:
- docker run -d -p 27002:27017 mongo:2
- docker run -d -p 27003:27017 mongo:3
- docker run -d -p 27017:27017 mongo:$MONGODB
- docker ps -a

script:
- if [[ $TRAVIS_NODE_VERSION != "0.12" ]]; then npm run lint; fi;
- npm run transpile
- if [[ $TRAVIS_NODE_VERSION == "0.12" ]]; then MONGODB_URL=mongodb://localhost:27003/connect-mongo-test npm run test-unit-es5; fi;
- if [[ $TRAVIS_NODE_VERSION != "0.12" ]]; then MONGODB_URL=mongodb://localhost:27002/connect-mongo-test npm run cover; fi;
- if [[ $TRAVIS_NODE_VERSION != "0.12" ]]; then MONGODB_URL=mongodb://localhost:27003/connect-mongo-test npm run test-unit; fi;
- if [[ $TRAVIS_NODE_VERSION != "0.12" ]]; then npm install mongodb@1.x; fi;
- if [[ $TRAVIS_NODE_VERSION != "0.12" ]]; then MONGODB_URL=mongodb://localhost:27002/connect-mongo-test npm run test-unit; fi;
- if [[ $TRAVIS_NODE_VERSION != "0.12" ]]; then MONGODB_URL=mongodb://localhost:27003/connect-mongo-test npm run test-unit; fi;
- yarn lint
# turn off lint for the moment
- MONGODB_URL=mongodb://localhost/connect-mongo-test travis_retry yarn test

after_script:
- if [[ $TRAVIS_NODE_VERSION != "0.12" ]]; then npm install coveralls && cat ./coverage/lcov.info | coveralls; fi;
after_success:
- npm install coveralls -g && yarn test --coverageReporters=text-lcov | coveralls
7 changes: 7 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"editor.formatOnSave": false,
"editor.formatOnPaste": false,
"editor.tabSize": 2,
"eslint.autoFixOnSave": true,
"javascript.updateImportsOnFileMove.enabled": "never",
}
47 changes: 46 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,48 @@
3.0.0 / 2019-06-17
================

__Breaking changes:__
* __Drop__ Node.js 4 & 6 support
* __Add__ Node.js 10 & 12 support
* Upgrade `mongoose` to v5 and `mongodb` to v3 and drop old version support
* Replace deprecated mongo operation
* MongoStore need to supply client/clientPromise instead of db/dbPromise due to depns upgrade

__Others changes:__
* __Add__ Implement store.all function (#291)
* __Add__ Add option writeOperationOptions (#295)
* __Add__ Transparent crypto support (#314)
* Change test framework from Mocha to Jest
* Change linter from xo to eslint

2.0.3 / 2018-12-03
================

* __Fix__ interval autoremove mode to use current date with every interval (#304, #305) (jlampise)

2.0.2 / 2018-11-20
================

* __Fix__ #300 DeprecationWarning: collection.remove is deprecated. Use deleteOne, deleteMany, or bulkWrite instead
* __Fix__ #297 DeprecationWarning: collection.update is deprecated. Use updateOne, updateMany, or bulkWrite instead

2.0.1 / 2018-01-04
================

* __Fix__ #271 TypeError: cb is not a function (brainthinks)

2.0.0 / 2017-10-09
=================

* __Drop__ Node.js 0.12 and io.js support
* __Drop__ MongoDB 2.x support
* __Drop__ mongodb driver < 2.0.36 support
* __Drop__ mongoose < 4.1.2 support
* __Fix__ `ensureIndex` deprecation warning ([#268](https://github.com/jdesboeufs/connect-mongo/issues/268), [#269](https://github.com/jdesboeufs/connect-mongo/pulls/269), [#270](https://github.com/jdesboeufs/connect-mongo/pulls/270))
* Improve `get()` ([#246](https://github.com/jdesboeufs/connect-mongo/pulls/246))
* Pass session in `touch` event
* Remove `bluebird` from dependencies

1.3.2 / 2016-07-27
=================

@@ -11,7 +56,7 @@
1.3.0 / 2016-07-23
=================

* __Add__ `create` and `update` events ([#215](https://github.com/kcbanner/connect-mongo/issues/215))
* __Add__ `create` and `update` events ([#215](https://github.com/jdesboeufs/connect-mongo/issues/215))
* Extend `mongodb` compatibility to `2.x`

1.2.1 / 2016-06-20
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2017 Jérôme Desboeufs

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Loading