Add optional delay property (in ms) to wait before snapping the photo.
Moved the delay