Wrap photo append into dedicated function
modified:   carousel.js