Skip to content

Commit

Permalink
[PUT] change name to title
Browse files Browse the repository at this point in the history
  • Loading branch information
Badr-Annabi committed Sep 16, 2024
1 parent 2e46ab7 commit 6e1aaf4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions server/models/movie.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,18 @@ class Movie(BaseModel, Base):
"""Representation of a user """
__tablename__ = 'movies'
tmdb_id = Column(Integer, nullable=False)
name = Column(String(128), nullable=False)
title = Column(String(128), nullable=False)
description = Column(String(2024), nullable=True)
poster = Column(String(512), nullable=True)
adult = Column(Boolean, nullable=True)
popularity = Column(Float, nullable=True)
year = Column(Integer, nullable=True)
rating = Column(Float, nullable=True)
language = Column(String(128), nullable=True)
# user_movies = relationship("User_Movie",
# back_populates="movie",
# cascade="all, delete-orphan")

def __init__(self, *args, **kwargs):
"""Initializes user"""
super().__init__(*args, **kwargs)
super().__init__(*args, **kwargs)

0 comments on commit 6e1aaf4

Please sign in to comment.