From ed984ef2e8e59b38d805057415a11ea2262afa4d Mon Sep 17 00:00:00 2001 From: Sergio Gutierrez Villalba Date: Wed, 22 Nov 2023 23:26:37 +0100 Subject: [PATCH] refactor(users): remove deprecated endpoint --- lib/server/routes/users.js | 29 ----------------------------- 1 file changed, 29 deletions(-) diff --git a/lib/server/routes/users.js b/lib/server/routes/users.js index 6a1d4c85..1f34f2b7 100644 --- a/lib/server/routes/users.js +++ b/lib/server/routes/users.js @@ -1,6 +1,5 @@ 'use strict'; -const assert = require('assert'); const Router = require('./index'); const middleware = require('storj-service-middleware'); const rawbody = middleware.rawbody; @@ -479,34 +478,6 @@ UsersRouter.prototype.confirmDestroyUser = function (req, res, next) { }); }; -/** - * Get user activation info - * @param {http.IncomingMessage} req - * @param {http.ServerResponse} res - * @param {Function} next - */ -UsersRouter.prototype.isActivated = function (req, res, next) { - const User = this.storage.models.User; - - log.debug('Getting user activation info for %s', req.headers['email']); - - User.findOne({ email: req.headers['email'] }, function (err, user) { - if (err) { - return next(new errors.InternalError(err.message)); - } - - if (!user) { - return next(new errors.BadRequestError('User not found')); - } - - // Send activated info - res.status(200).send({ - activated: user.activated, - uuid: user.uuid, - }); - }); -}; - UsersRouter.prototype.confirmDestroyUserStripe = function (req, res, next) { const self = this; const stripeUtils = require('../stripeService');