fixed getSlides function in api