Skip to content

Commit

Permalink
Fix lint :)
Browse files Browse the repository at this point in the history
  • Loading branch information
fjpacheco committed Mar 12, 2024
1 parent 87790fd commit 7e3c96c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion app/models/users.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@

class User(Base):
__tablename__ = "users"
__table_args__ = {'schema': environ.get("POSTGRES_SCHEMA", "users_service")}
__table_args__ = {'schema': \
environ.get("POSTGRES_SCHEMA", "users_service")}
id = Column(Integer, primary_key=True, index=True, autoincrement=True)
name = Column(String, nullable=True)
email = Column(String, nullable=False)
Expand Down
5 changes: 3 additions & 2 deletions app/repository/Users.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
from sqlalchemy import create_engine, engine
from sqlalchemy import create_engine
from sqlalchemy.orm import Session
from os import environ
from typing import Optional
from models.users import User


class UsersRepository:
db_url = environ.get("DATABASE_URL").replace("postgres://", "postgresql://", 1)
db_url = environ.get("DATABASE_URL") \
.replace("postgres://", "postgresql://", 1)

engine = create_engine(db_url)

Expand Down

0 comments on commit 7e3c96c

Please sign in to comment.