import { ANONYMOUS, AUTHENTICATED, INIT, LOADING, STUDENT } from '../constants';

export function isLoading(authStatus) {
  return [INIT, LOADING].includes(authStatus);
}

export function isAnonymous(authStatus) {
  return authStatus === ANONYMOUS;
}

export function isExactAuthenticated(authStatus) {
  return authStatus === AUTHENTICATED;
}

export function isAuthenticated(authStatus) {
  return [AUTHENTICATED, STUDENT].includes(authStatus);
}

export function isStudent(authStatus) {
  return authStatus === STUDENT;
}
