Q: "Calling an asynchronous function without callback is deprecated." But there is a call back I have a function that will handle the on-off state of pins based on the documents in a database. This function uses a lot of libraries and I believe that one of these is causing the deprecation (based on the deprecation tracking I included below my code snippet I think it is the OnOff Gpio Library for Raspberry PI). Which function is causing the deprecation? What would be the disadvantage to rolling back on the update of Node? I would really like to hear some opinions on this, Thank you in advance. 

MongoClient.connect(url, function (err, db) {
    if (err) {
        console.log('Unable to connect to the mongoDB server. Error:', err);
    } else {
        var collection = db.collection('re');//change as needed
        collection.findAndModify(
        {"restart":"sensor","value":false},
        {},
        {"$set":{"value":true}},
        {},
        function(err,result){
            if(err){
                throw err;
            }
            else{
                console.log(result);
                if(result.value!=null){
                    spin.write(0);
                    setTimeout(function() {
                        spin.write(1);
                    },10000);
                }
                else{
                    console.log("Sensor should stay on");
                    spin.write(1);
                }
            }
        });


    }
    db.close();
});



(node:10503) DeprecationWarning: Calling an asynchronous function
  without callback is deprecated.
at maybeCallback (fs.js:98:42)
at Object.fs.write (fs.js:703:16)
at Gpio.write (/home/pi/node_modules/onoff/onoff.js:190:6)
at Object. (/home/pi/local-opio/final:16:6)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
at Module.runMain (module.js:605:10)
at run (bootstrap_node.js:422:7)
at startup (bootstrap_node.js:143:9)
at bootstrap_node.js:537:3


A: It looks like you have 3 calls to the onoff package's write function without optional callbacks. Try passing an appropriate callback (that takes an err argument) to each of those calls.
