This will call the api to inspect every image, when you only want to retrieve one. Change this to directly call inspectImage.