From f0aafcc4c6e9f57fa03e56372970a14132dc2495 Mon Sep 17 00:00:00 2001 From: Artucuno Date: Sun, 28 Jan 2024 19:18:33 +1100 Subject: [PATCH] Update abstract_repository.py --- pydantic_mongo/abstract_repository.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/pydantic_mongo/abstract_repository.py b/pydantic_mongo/abstract_repository.py index 2e37040..ec17e32 100644 --- a/pydantic_mongo/abstract_repository.py +++ b/pydantic_mongo/abstract_repository.py @@ -1,3 +1,4 @@ +import asyncio from typing import ( Any, Dict, @@ -10,12 +11,11 @@ TypeVar, Union, Mapping, - List, ) -import asyncio - +import nest_asyncio from bson import ObjectId +from motor import motor_asyncio from motor.motor_asyncio import AsyncIOMotorDatabase from pydantic import BaseModel from pymongo import UpdateOne @@ -23,8 +23,6 @@ from pymongo.database import Database from pymongo.results import InsertOneResult, UpdateResult, DeleteResult, BulkWriteResult, InsertManyResult -from motor import motor_asyncio - from .pagination import ( Edge, decode_pagination_cursor, @@ -32,7 +30,6 @@ get_pagination_cursor_payload, ) -import nest_asyncio nest_asyncio.apply() T = TypeVar("T", bound=BaseModel)