Commit c65b1ffd authored by Ahmad Anvari's avatar Ahmad Anvari

add static method get_client

parent 8d241fb3
...@@ -6,6 +6,10 @@ client = MongoClient() ...@@ -6,6 +6,10 @@ client = MongoClient()
class Model(ABC): class Model(ABC):
@staticmethod
def get_client():
return client
@staticmethod @staticmethod
def get_db(): def get_db():
return client['shoppe'] return client['shoppe']
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment