Added another check to tasks