//File: controllers/userController.js var mongoose = require('mongoose'); var userModel = mongoose.model('userModel'); /* */ var jwt = require('jsonwebtoken'); // used to create, sign, and verify tokens var express = require("express"); var app = express(); var config = require('../config'); // get our config file app.set('superSecret', config.secret); // secret variable /* */ //GET - Return all Users in the DB exports.findAllUsers = function(req, res) { userModel.find(function(err, users) { if(err) res.send(500, err.message); //password deletion for(var i=0; i