added self-check