export const listToMaybe = xs => {
  if (isList(xs) === false) { return error.listError(xs, listToMaybe); }
  return isEmpty(xs) ? Nothing : just(head(xs));
}