Skip to content

Commit

Permalink
Remove unused conflictFlag
Browse files Browse the repository at this point in the history
  • Loading branch information
Jim Yeh committed Mar 20, 2020
1 parent 9d7e699 commit 39bd962
Showing 1 changed file with 15 additions and 18 deletions.
33 changes: 15 additions & 18 deletions schema/facebook/post.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,38 +57,35 @@ type PostMediaORM struct {
DataOwnerID string `gorm:"unique_index:facebook_postmedia_owner_post_id_timestamp_unique"`
Post PostORM `gorm:"foreignkey:PostID" json:"-"`
PostID uuid.UUID `gorm:"unique_index:facebook_postmedia_owner_post_id_timestamp_unique"`
ConflictFlag bool
}

func (PostMediaORM) TableName() string {
return "facebook_postmedia"
}

type PlaceORM struct {
ID uuid.UUID `gorm:"type:uuid;primary_key" sql:"default:uuid_generate_v4()"`
Name string
Address string
Latitude float64
Longitude float64
DataOwnerID string `gorm:"unique_index:facebook_place_owner_timestamp_unique"`
Post PostORM `gorm:"foreignkey:PostID" json:"-"`
PostID uuid.UUID `gorm:"unique_index:facebook_place_owner_timestamp_unique"` // NOTE: one place per post
ConflictFlag bool
ID uuid.UUID `gorm:"type:uuid;primary_key" sql:"default:uuid_generate_v4()"`
Name string
Address string
Latitude float64
Longitude float64
DataOwnerID string `gorm:"unique_index:facebook_place_owner_timestamp_unique"`
Post PostORM `gorm:"foreignkey:PostID" json:"-"`
PostID uuid.UUID `gorm:"unique_index:facebook_place_owner_timestamp_unique"` // NOTE: one place per post
}

func (PlaceORM) TableName() string {
return "facebook_place"
}

type TagORM struct {
ID uuid.UUID `gorm:"type:uuid;primary_key" sql:"default:uuid_generate_v4()"`
DataOwnerID string `gorm:"unique_index:facebook_tag_owner_post_friend_unique"`
Post PostORM `gorm:"foreignkey:PostID" json:"-"`
PostID uuid.UUID `gorm:"unique_index:facebook_tag_owner_post_friend_unique"`
Friend FriendORM `gorm:"foreignkey:FriendID" json:"-"`
FriendID uuid.UUID `gorm:"unique_index:facebook_tag_owner_post_friend_unique"`
FriendName string
ConflictFlag bool
ID uuid.UUID `gorm:"type:uuid;primary_key" sql:"default:uuid_generate_v4()"`
DataOwnerID string `gorm:"unique_index:facebook_tag_owner_post_friend_unique"`
Post PostORM `gorm:"foreignkey:PostID" json:"-"`
PostID uuid.UUID `gorm:"unique_index:facebook_tag_owner_post_friend_unique"`
Friend FriendORM `gorm:"foreignkey:FriendID" json:"-"`
FriendID uuid.UUID `gorm:"unique_index:facebook_tag_owner_post_friend_unique"`
FriendName string
}

func (TagORM) TableName() string {
Expand Down

0 comments on commit 39bd962

Please sign in to comment.