Update mongoose dependency to 8.x

-A couple small fixes were applied to the database.js to change the alias of findOneAndRemove to findOneAndDelete to fix breaking changes
This commit is contained in:
Joe Uhren
2023-12-27 17:08:24 -07:00
parent accf9a981d
commit ed8d7a5964
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -460,7 +460,7 @@ module.exports = {
// check if the claim name is being removed
if (claim_name == null || claim_name == '') {
// remove the claim name
ClaimAddress.findOneAndRemove({a_id: hash}).then(() => {
ClaimAddress.findOneAndDelete({a_id: hash}).then(() => {
// run processes after the claim name has been updated
after_update_claim_name(hash, claim_name, function() {
return cb('');
@@ -1045,7 +1045,7 @@ module.exports = {
// drops richlist data for given coin
delete_richlist: function(coin, cb) {
Richlist.findOneAndRemove({coin: coin}).then((exists) => {
Richlist.findOneAndDelete({coin: coin}).then((exists) => {
if (exists)
return cb(true);
else
+1 -1
View File
@@ -39,7 +39,7 @@
"intl": "^1.2.5",
"jsonminify": "^0.4.2",
"mongodb": "^6.1.0",
"mongoose": "^7.1.0",
"mongoose": "^8.0.3",
"morgan": ">=1.10.0",
"postman-request": "^2.88.1-postman.31",
"pug": "~3.0.2",