Handle empty batches.

Previously batch operations on books without pages would have failed.