maestro-server/analytics-front

View on GitHub
app/core/applications/validator/validAccessEmpty.js

Summary

Maintainability
A
0 mins
Test Coverage
'use strict';

const _ = require('lodash');
const PermissionError = require('core/errors/factoryError')('PermissionError');

module.exports = function (e) {
    if (_.isEmpty(e))
        throw new PermissionError('You not authorize to do this!');

    return e;
};