Issue #8732 by tuj: Added check for existance to slide directive