diff --git a/mealie/repos/repository_users.py b/mealie/repos/repository_users.py index 537be987c..e08e552c1 100644 --- a/mealie/repos/repository_users.py +++ b/mealie/repos/repository_users.py @@ -39,7 +39,7 @@ class RepositoryUsers(GroupRepositoryGeneric[PrivateUser, User]): users_assets.img_random_3, ] random_image = random.choice(all_images) - shutil.copy(random_image, new_user.directory() / "profile.webp") + shutil.copyfile(random_image, new_user.directory() / "profile.webp") return new_user diff --git a/mealie/services/openai/openai.py b/mealie/services/openai/openai.py index 5207b6cc6..b872f9953 100644 --- a/mealie/services/openai/openai.py +++ b/mealie/services/openai/openai.py @@ -233,7 +233,7 @@ class OpenAIService(BaseService): try: with get_temporary_path() as temp_path: image_path = temp_path / "recipe-image.jpg" - shutil.copy(self.TESTING_DIR / "recipe-image.jpg", image_path) + shutil.copyfile(self.TESTING_DIR / "recipe-image.jpg", image_path) response = await self.ping( provider,