Create the directory at screenshotsURL before trying to save the image to it.
Log errors if writing a screenshot fails.
Refs #8.