From 1f7749b80a1d2ba3baab0d34eb53d3b22d37f507 Mon Sep 17 00:00:00 2001 From: Ethan Dalool Date: Thu, 22 Mar 2018 23:11:25 -0700 Subject: [PATCH] PDB.new_album call album.add_photos instead of add_photo. --- etiquette/photodb.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/etiquette/photodb.py b/etiquette/photodb.py index eec50cf..88258e0 100644 --- a/etiquette/photodb.py +++ b/etiquette/photodb.py @@ -107,9 +107,8 @@ class PDBAlbumMixin: album.add_associated_directory(associated_directory, commit=False) if photos is not None: - for photo in photos: - photo = self.get_photo(photo) - album.add_photo(photo, commit=False) + photos = [self.get_photo(photo) for photo in photos] + album.add_photos(photos, commit=False) if commit: self.log.debug('Committing - new Album')