Commit 71edffe0 authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen

Movie: Make mediaId immutable

parent 1aa95e97
......@@ -38,11 +38,11 @@ int64_t Movie::* const Movie::Table::PrimaryKey = &Movie::m_id;
Movie::Movie(MediaLibraryPtr ml, sqlite::Row& row )
: m_ml( ml )
, m_id( row.extract<decltype(m_id)>() )
, m_mediaId( row.extract<decltype(m_mediaId)>() )
, m_summary( row.extract<decltype(m_summary)>() )
, m_imdbId( row.extract<decltype(m_imdbId)>() )
{
row >> m_id
>> m_mediaId
>> m_summary
>> m_imdbId;
}
Movie::Movie( MediaLibraryPtr ml, int64_t mediaId )
......
......@@ -57,7 +57,7 @@ class Movie : public IMovie, public DatabaseHelpers<Movie>
private:
MediaLibraryPtr m_ml;
int64_t m_id;
int64_t m_mediaId;
const int64_t m_mediaId;
std::string m_summary;
std::string m_imdbId;
......
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