blob: ac46e2257bf3404dc74475407bd577e6af243dc0 (
plain)
1
2
3
4
5
6
7
8
9
|
import { iff, isNot } from 'feathers-hooks-common';
import { NotAuthenticated } from '@feathersjs/errors';
import isAuthenticated from './isAuthenticated';
export default iff(
isNot(isAuthenticated),
() => { throw new NotAuthenticated('This endpoint requires auth!') }
);
|